Python Assignment Questions - 240427 - 125116
Python Assignment Questions - 240427 - 125116
Module -1 Questions
1. With Python programming examples to each, explain the syntax and control flow
diagrams of break and continue statements.
2. Explain TWO ways of importing modules into application in Python with syntax and
suitable programming examples.
3. Write a function to calculate factorial of a number. Develop a program to compute
binomial coefficient (Given N and R).
4. Develop a Python program to generate Fibonacci sequence of length (N). Read N from
the console.
5. Explain looping control statements in Python with a syntax and example
6. Explain FOUR scope rules of variables in Python.
7. What is the need for role of precedence? Illustrate the rules of precedence in Python
with example.
8. Explain the local and global scope with suitable examples.
9. Develop a program to generate Fibonacci sequence of length (N). Read N 8 from the
console.
10. What are functions? Explain Python function with parameters and return statements.
11. Define exception handling. How exceptions are handled in python? Write a program to
solve divide by zero exception.
12. explain With an example explain user defined functions. With an example explain the
following built-in functions: i) print() ii) input iii) len().
13. How to handle exceptions in Python explain with an example.
14. Write a program to print even numbers using step size in range().