SEMESTER-I
25BTAD141G PYTHON PROGRAMMING 5H-4C
Instruction Hours/week: L:3 T:0 P:2 Marks: Internal:40 External:60 Total:100
End Semester Exam: 3 Hours
Pre-requisites: Nil
COURSE OBJECTIVES:
The goal of this course is for students to
Learn about basic python syntax and semantics like control structures and functions.
Develop logical thinking abilities and to propose novel solutions for real world problems
through object-oriented programming concepts.
Model the empirical knowledge on applying programming on business domains.
COURSE OUTCOMES:
Upon completion of this course students will be able to
Interpret the basic representation of the data structures and sequential programming K2
Solve the problems using list, dictionaries, tuples, and sets core data structures K3
Build applications using functions, modules and packages K3
Examine the error-handling constructs for unanticipated states/inputs. K4
Analyze the applications on real-world problems using object-oriented concepts K4
UNIT I INTRODUCTION TO PYTHON BASICS 9
Fundamentals of Computing - Building blocks of algorithms - Introduction to Programming - Elements
of python - Variables - Data Types - Operators - Operator Precedence - Expressions - Conditional
statement - Loops - Break, Continue and Pass - Illustrative problems: square root, GCD, LCM, Sum an
array of numbers, Linear search, Binary search.
UNIT II PYTHON DATA STRUCTURES 9
Mutable vs immutable data types - String - Indexing and slicing - String functions - List - List slices -
List methods - Iterate over a list - Mutability - Aliasing - Cloning lists - List parameters - List
comprehension- Tuples- Tuple assignment - Tuple as return value - Dictionaries - Operations and
methods - Set - Set operations - Illustrative programs: Simple sorting, pattern matching, Fibonacci,
Factorial, Prime numbers.
UNIT III FUNCTIONS, MODULES AND PACKAGES 9
Built-in functions - User defined functions - Creating function - Calling functions - Types of function
arguments - Recursion and lambda or anonymous functions - Packages: Defining - Creating and
accessing a package - Python libraries NumPy, pandas, Matplotlib - Flask/Django
UNIT IV FILE HANDLING, CLASS AND OBJECT 9
Introduction to files - File path - Opening and closing files - Reading and writing files - File position -
Decorators - Introduction to elements of OOP - Class - Object - Inheritance - Data abstraction -
Encapsulation - Polymorphism - UML class diagram - Access specifiers - Creating classes - Creating
object - Accessing members - init() method - Instance, static and class methods - Importance of self -
Implementing encapsulation. Illustrative programs: File operations on TEXT and CSV, Scientific
calculator using class and objects.
UNIT V ERROR HANDLING, TESTING 9
Exception handling with try, except, finally - Exception handling: Errors vs exceptions - Handling
exceptions - Raising exception - Creating user defined exception - Debugging techniques- Unit testing
with unit test - Writing test cases - web scraping - Data analysis project - Automation script
TOTAL: 45
LIST OF EXPERIMENTS:
1.
Write conditional and looping statements in Python.
2.
Create and manipulate strings using indexing, slicing, and various string functions.
3.
Create and manipulate lists using operations, slices, methods, list comprehension,
and looping.
4. Create and manipulate tuples, dictionaries, and sets, and understand the differences
between mutable and immutable types.
5. Implement user-defined functions and understand the different types of function
arguments, such as positional, keyword, and default arguments.
6. Implement inheritance and understand the different types of inheritance.
7. Implement polymorphism through method overloading, overriding, and
operator overloading.
TOTAL: 30
TEXT BOOKS:
[Link] B Downey,Jeffrey Elkne, Chris Meyers ,”How to Think Like a Computer
Scientist: Learning with Python 3 Documentation”,3rd Edition, Green Tea Press,2020.
2. Steven F. Lott ,Dusty Phillips,”Python Object-Oriented Programming: Build robust and
maintainable object-oriented Python applications and libraries”4th Edition , Packt
Publishing Limited ,2021.
REFERENCE BOOKS:
1.R. Nageswara Rao,” Core Python Programming”, 3rd Edition, Dream tech Press,2022.
[Link] Lutz , “Learning Python” ,5th Edition , O’Reilly Publication , 2018.
[Link] and Summerfield , “Programming in Python 3”,2ndEdition ,Dorling Kindersley
India Pvt. Ltd, 2019.
WEBSITES:
1. [Link]
2. [Link]/python-programming
3. [Link]
4. [Link]
CO, PO, PSO Mapping
COs PO1 PO2 PO3 PO4 PO5 PO6 PO7 PO8 PO9 PO10 PO11 PSO1 PSO2
CO1 2 1 - - - - - 2 2 - 3 1 -
CO2 3 2 1 - - - - 2 2 - 3 1 -
CO3 3 2 1 - - - - 2 2 - 3 1 -
CO4 3 3 2 1 - - - 2 2 - 3 1 -
CO5 3 3 2 1 - - - 2 2 - 3 1 -
AVG 2.8 2.4 1.4 1 - - - 2 2 - 3 1 -
1 - Low, 2 - Medium, 3 - High, ‘-' - No Correlation