Python Programming
General Course Information
Course Code: PCC-IT308-T/ Course Assessment Methods (internal: 30; external: 70) Two minor
PCC-CSE302-T examinations (20 marks), Class Performance measured through
Course Credits: 3 percentage of lectures attended (4 marks), assignments (6 marks), and
the end- semester examination (70 marks).
Type: Professional Core
For the end semester examination, nine questions are to be set by the
Contact Hours: 3hours/week
examiner. A candidate is required to attempt 5 questions in all. All
Mode: Lectures (L)
questions carry equal marks. Question number 1 will be compulsory and
Examination Duration: 3 hours based on the entire syllabus. It will contain seven parts of 2 marks each.
Question numbers 2 to 9 will be given by setting two questions from
each of the four units of the syllabus. A candidate is required to attempt
the remaining four questions by selecting one question from each of the
four units.
Pre-requisite: Exposure to programming languages
About the Course:
Python is a popular open source programming language used for both standalone programs and scripting
applications in a wide variety of domains. It is free, portable, and powerful and is both relatively easy and
remarkably fun to use. lity in machine learning, data analytics
and many other data science application. This is introductory course and covers most of the basic concepts
required for basic python programming. Some of the contents are advanced may be useful for data analytics
purpose.
Course Outcomes: By the end of the course students will be able to:
CO1. outline various basic programming constructs including operators, character sets, basic data types and
control statements. (LOTS: level 1: Understand)
CO2. explain Python packages and their functionalities for data analysis. (LOTS: level 2: Understand)
CO3. solve problems using python programming. (LOTS: level 3: Apply)
CO4. analyse the results of data analysis or machine learning programs (HOTS: level 4: Analyse)
CO5. evaluate solutions according to the problem definition. (HOTS: level 5: Evaluate)
CO6. develop database applications in Python. (HOTS: level 6: Create)
Course Content
Unit I
Introduction to Python, History of Python, Features of Python, Python Identifiers, Python Character Set,
Keywords and Indentation, Comments, Command Line Arguments, Assignment Operator, Operators and
Expressions, print() Function, input() Function, eval() Function, Python Data Types: int, float, complex,
Variables, Mutable vs Immutable variables, Namespaces, Decision Statements: Boolean Type, Boolean
Operators, if statement, else statement, Nested Conditionals Statements, Multi-way Decision Statements (elif
statement).
Unit II
Loop Control Statements: While loop, range() Function, For Loop, Nested Loops, Infinite Loop, Break
Statement, Continue Statement, Pass Statement, Introduction to Strings, String Operations: Indexing and
Slicing, Lists: Operations on List: Slicing, Inbuilt Functions for Lists, List Processing: Searching and Sorting,
Dictionaries: Need of Dictionary, Operations on Directories: Creation, Addition, Retrieving Values, Deletion;
Tuples, operations on Tuples, Inbuilt Functions for Tuples, Introduction to Sets, operations on sets.
Python Functions, Inbuilt functions, Main function, User Defined functions, Defining and Calling Function,
Parameter Passing, Actual and Formal Parameters, Default Parameters, Global and Local Variables, Recursion,
Passing Functions as Data, Lamda Function, Modules, Importing Own Module, Packages.
Unit III
Operations on File: Reading text files, read functions, read(), readline() and readlines(), writing Text Files,
write functions, write() and writelines(),Manipulating file pointer using seek, Appending to Files.
Python Object Oriented: Overview of OOP, Classes and objects, Accessing attributes, Built-In Class
Attributes, Methods, Class and Instance Variables, Destroying Objects, Polymorphism, Overlapping and
Overloading of Operators, Class Inheritance: super(), Method Overriding, Exception Handling, Try-except-else
clause, Python Standard Exceptions, User-Defined Exceptions
Unit IV
Databases in Python: Create Database Connection, create, insert, read, update and delete Operation, DML and
DDL Operation with Databases.
Python for Data Analysis: numpy: Creating arrays, Using arrays and Scalars, Indexing Arrays, Array
Transposition, Universal Array Function, Array Processing, Array Input and Output
Pandas: Series, Data Frame, Panel, Index objects, Re-indexing, Iteration, Sorting. Matplotlib: Python for Data
Visualization, Visualization Section, Sklearn: loading of dataset, learning and predicting, Model Persistence.
Text and Reference Books:
1. Ashok Namdev Kamthane, Programming and Problem Solving with Python, Mc Graw Hill Education
Publication, 2018.
2. John Guttag, Introduction to Computation and Programming using Python, Springer, Revised and
Expanded version (Referred by MIT), 2013.
3. Lutz, M., Learning Python: Powerful Object-Oriented Programming. O'Reilly Media, Inc., 2013.
4. Michael T Goodrich and Robertto. Thamassia, Micheal S Goldwasser, Data Structures and Algorithms
in Python, Wiley, 2016.
5. Y. Daniel Liang, Introduction to Programming Using Python, Pearson, 2013.
6. Reema Thareja, Python Programming Using Problem Solving Approach , Oxford Publications, 2017.
7. Dr. R. Nageswara Rao, Allen B. Downey, Core Python Programming , Think Python Media,
2012.
8. Kenneth A. Lambert, The Fundamentals of Python: First Programs, Cengage Learning, 2011.
CO-PO Articulation Matrix Python Programming Course (PCC-IT308-T)
List of Course Outcomes PO1 PO2 PO3 PO4 PO5 PO6 PO7 PO8 PO9 PO10 P
CO1. Outline various basic programming constructs including
operators, character sets, basic data types and control 1 _ _ _ _ _ _ _ _ _
statements. (LOTS: level 1: Understand)
CO2. Explain Python packages and their functionalities for data
1 _ _ _ _ _ _ _ _ _
analysis. (LOTS: level 2: Understand)
CO3. Solve problems using python programming. (LOTS: level 3:
3 2 2 _ 3 _ _ _ _
Apply)
CO4. Analyse the results of data analysis or machine learning
2 3 2 2 _ _ _ _ _ _
programs (HOTS: level 4: Analyse)
CO5. Evaluate solutions according to the problem definition.
2 3 2 2 _ _ _ _ _ _
(HOTS: level 5: Evaluate)
CO6. Develop database applications in Python. (HOTS: level 6:
3 3 2 3 3 _ _ _ _
Create)
Level of Attainments PCC-IT308-T