Python Programming
Number of Contact Hours: 30hrs
Course Evaluation: Practical – 20 Marks + Written Exam – 80 Mark
Outcome of the Course: Understand various statements, data types and
functions in Python Develop programs in Python programming
language
Python Objectives of the Course:
● To learn basics of Python programming
● To learn decision making, looping and functions in Python
Module 1
Introduction to python, features, IDLE, python interpreter, Writing and
executing python scripts, comments, identifiers, keywords, variables,
data type, operators, operator precedence and associativity, statements,
expressions, user inputs, type function, eval function, print function.
Module 2
Boolean expressions, Simple if statement, if-elif-else statement,
compound Boolean expressions, nesting, multi way decisions. Loops:
The while statement, range functions, the for statement, nested loops,
break and continue statements, infinite loops.
Module 3
Functions, built-in functions, mathematical functions, date time
functions, random numbers, writing user defined functions, composition
of functions, parameters and arguments, default parameters, function
calls, return statement, using global variables, recursion.
Module 4
String and string operations, List- creating list, accessing, updating and
deleting elements from a list, basic list operations.
References:
1. E. Balaguruswamy, Introduction to Computing and Problem Solving
Using Python
2. Richard L. Halterman, Learning To Program with Python
Practical Questions
1. Python program to add two numbers
2. Maximum of two numbers in Python
3. Python Program for factorial of a number
4. Python Program for simple interest
5. Python Program for compound interest
6. Python Program to check Armstrong Number
7. Python Program for Program to find area of a circle
8. Python program to print all Prime numbers in an Interval
9. Python program to check whether a number is Prime or not
10. Python Program for n-th Fibonacci number