Miet Public School Class 12 Computer Science Program List For Practical File
Miet Public School Class 12 Computer Science Program List For Practical File
Term 1:-
1. Write a program in python script that reads a line and print its statistics like:
Number of uppercase letters:
Number of lowercase letters:
Number of alphabets:
Number of digits:
2. Write a program to prepare a list in python & the data should be like :
[‘Student Name’, Student Age, ‘Student Address’]
Append an element Student RollNo in the list and also insert Student class after Student Age.
3. Given three lists as list1=[‘a’,’b’,’c’], list2=[‘h’,’i’,’t’] and list3=[‘0’,’1’,’2’]. Write a program that
adds individual elements of list2 and list3 to list1. The resultant should be in the order of
elements of list3,elements of list1, elements of list2.
4. Write a program that checks for the presence of a value inside a dictionary and print its key.
5. Write a code to find a factorial of a given number. Input should be taken by user.
6. Create a binary file with RollNo,Name,and Marks. Input a RollNo and update the marks.
7. Read a text file and display the numbers of vowels,constants,uppercase,lowercase characters in
the file.
8. Write a program that finds an element’s index/position in a Tuple without using index().
9. Write a program to check whether the given number is palindrome or not.
10. Write a program in python to print the reverse of a given string.
11. Write a program that receives two numbers in a function and returns the results of all
Arithmetic opertaors i.e. (+,-,*,/,%) on these numbers.
12. Write a python program to print the table of a given number using for loop.
13. Write a program to display the number of lines in the text file.
14. Write a program to get the RollNo,Names,&Marks of the given Student in a class(get from user)
& store these details in a text file “Marks.txt”
15. Write a program to a binary file calles “emp.dat”and write into it the employee details of some
employees, available in the form of dictionaries.
16. Write a program to create a csv file “employee.csv” by suppressing the EOL translation .
Data contained in the file should be:-
[‘EmpNo’:1001, ‘Name’:’Ishika’, ‘Designation’:’Manager’,’Salary’:56000
‘EmpNo’:1002, ‘Name’:’Kush’, ‘Designation’:’Team lead’,’Salary’:95000
‘EmpNo’:1003, ‘Name’:’Madhur’, ‘Designation’:’Project Head’,’Salary’:100000
‘EmpNo’:1004, ‘Name’:’Kavyansh’, ‘Designation’:’Project Manager’,’Salary’:70000
‘EmpNo’:1005, ‘Name’:’Ishita’, ‘Designation’:’Relational Manager’,’Salary’:60000]
Term 2:-
17. Create the table Customer as per following Table Instance Chart:-
Now perform the following queries in Sql according to the above table:-
18. Create the table Employee and insert the data as per following Table Instance Chart:-
19. Write a program that displays first 3 rows fetched from table Student of MySql Database "test".
20. Write a program that displays first 5 rows fetched from table Employee of MySql database "test".
Use pymsql to connect with the database