Python Lab Manual 2024
Python Lab Manual 2024
Lab Manual
Given:
names=["ajay","sneha","vivek","pooja","sagar","riddhi"]
roll_nos=(101,102,103,104,105,106)
Perform operations:
{'ajay': 101, 'sneha': 102, 'vivek': 103, 'pooja': 104, 'sagar': 105, 'riddhi': 106}
Assignment for Q1.
Q.3. Create a module name ‘Calculate’ and add 4 methods in it add(),substract(),multiply(), and
divide(), create another module named as ‘operations’ and import ‘Calculate’ module in it and use
its function.
Assignment for Q.3.
1) Explain user-defined module in python
2) Explain any 2 built in modules in python.
Assignment for Q. 4:
1) Explain Regular expression in python ? explain various components used in regular expression.
Q.7. Write a program and create 2 threads in python , one should print square of a numbers (1-10)
while other should print the cube of the numbers. ( 1-10)
Q.8. Write Programs to perform searching, adding, updating the content from the file.
Q.10. Create a django project which contain login page and if user enters username=”iims” and
password=”python” then redirect user to dashboard which having welcome message.