Professional Documents
Culture Documents
Suryansh Pratical
Suryansh Pratical
M
2023-24
ACADEMIC YEAR: 2022-23
COMPUTER SCIENCE PRACTICAL FILE ON PYTHON
AND MYSQL
Roll No.- 36
NON
Stream- Medical
MEDICAL
Subject- Computer
Science(083)
CERTIFICATE
She
He has taken keen interest and shown utmost sincerity
sir, for his coordination in extending every possible support for the
thank to my classmates for their timely help and support for the
Last but not the least, I would like to thank those who had helped
Output-
Source File-
2. WAP to read a text file and display the number of vowels,
consonants, uppercase and lowercase characters in the
file.
Source Code-
Output-
Source File-
3. WAP to remove all the lines that contain the character “a”
in a file and write it to another file.
Source Code-
Output-
Before-
After-
4. WAP to create a binary file with name and roll no.,
search for a given roll no. and display the name (if not
found display appropriate message). Source Code-
Output-
5. WAP to create a binary file with roll no., name and
marks, input a roll no. and update the marks.
Source Code-
Output-
6. WAP to create a CSV file by entering user id and
password, read and search the password for the given user
id.
Source Code-
Output-
7. WAP of random number generator that generate random
numbers between 1 and 6 (simulates a dice).
Source Code-
Output-
8. WAP to calculate simple interest using function INSERT
() that can receive principal amount, time, rate and return
the simple interest. Do specific default value for rate and
time as 10% and five years respectively.
Source Code-
Output-
9. WAP a program to find the factorial of a given number
using function.
Source Code-
Output-
10. WAP to find the area and perimeter of circle using user
defined module.
Source Code-
Output-
Source Code-
Output-
12. WAP for implementation of stack using list.
Source Code-
Output-
13. WAP to implement a stack for these book details (book
number, book name) implement push, pop and display
operation.
Source Code-
Output-
14. WAP to create a table EMPLOYEE with the
following structure and display the structure after
creation.
Source Code-
Outpur-
15. WAP to insert five records into the table
EMPLOYEE and display the table contents after
insertion.
Source Code-
Output-
16. WAP to display the details of employee in
ascending order of their salary.
Source Code-
Output-
17. WAP to connect with database, insert record
entered by the user in a table and display all the
records.
Source Code-
Output-
18. WAP to search the record in mysql table using python,
if not found display appropriate message.
Source Code-
Output-
19. WAP to update the record in mysql table using python,
if not found display appropriate message.
Source Code-
Output-
Checking of updation-
20. WAP a program to delete the particular record in mysql
table using python.
Source Code-
Output-