0% found this document useful (0 votes)
6 views1 page

Important Questions Ia1

The document outlines various Python programming concepts and tasks, including string and list operations, control flow statements, exception handling, and variable scope. It provides examples for string concatenation, list operations, Fibonacci sequence generation, and the use of functions, among others. Additionally, it discusses the rules for variable names and methods for importing modules in Python.

Uploaded by

shravaniav2
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views1 page

Important Questions Ia1

The document outlines various Python programming concepts and tasks, including string and list operations, control flow statements, exception handling, and variable scope. It provides examples for string concatenation, list operations, Fibonacci sequence generation, and the use of functions, among others. Additionally, it discusses the rules for variable names and methods for importing modules in Python.

Uploaded by

shravaniav2
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

MODULE1 AND MODULE2 (LISTS)

1. Illustrate string concatenation and replication with an example.


2. Illustrate List concatenation and replication with an example.
3. Exemplify if-else, for and while statements with an example and flowchart
4. Illustrate the rules of precedence in python. Demonstrate the steps how Python is
evaluating the below expression and reduces it to a single value.
a) (5 - 1) * ((7 + 1) / (3 - 1))
b) 3/2 * 4 + 3 + (10 / 4 )**3 - 2
5. Exemplify return values and return statements with an example.
6. Demonstrate keyword arguments in print( ) function with an example
7. Develop a Python program to generate Fibonacci sequence of length (N).Read N from
the console
8. Develop a program to read the name and year of birth of a person. Display whether
the person is a senior citizen or not.
9. Exemplify local and global scope with local and global variable with an example
10. Differentiate between local and global scope with local and global variable with an
example
11. Define Exception handling. How exceptions are handled in python? Write a program
to solve divide by zero exception.
12. Illustrate the use of in and not in operators in list with suitable examples.
13. If S=’Hello Python World’, Illustrate the output of the following statements:
a) S[1:5] b) S[:5] c) S[3:-1] d) S[:] e) S[2:7] f) S[:-2]
14. Explain negative indexing, del, index(), append(), remove() with suitable examples.
15. Explain slicing, insert(), sort(), len() and remove() with suitable examples.
16. Illustrate with examples print( ) and input( ) functions
17. Discuss the various methods of importing modules in python program with an
example.
18. Define Variable. List and explain the rules for variables names in python. Give
examples for valid and invalid variable names.
19. Define functions? Explain python functions with parameters and return statements.
20. With Python programming examples to each, explain the syntax and control flow
diagrams of break and continue statements.
21. Define List. Explain getting individual values in a list with an index with an example.

You might also like