0% found this document useful (0 votes)
221 views

Python Programming Lab Lab INTERNAL 2 (Lateral Entry Students) Course Code

The document outlines a Python programming lab with 15 experiments involving various Python programming concepts and tasks. The experiments include writing programs to count vowels, sort words in files, find common letters in strings, sort lists by vowel count, create classes to represent people and circles, work with dictionaries, arrays, matrices, and create a basic calculator using tkinter.
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
221 views

Python Programming Lab Lab INTERNAL 2 (Lateral Entry Students) Course Code

The document outlines a Python programming lab with 15 experiments involving various Python programming concepts and tasks. The experiments include writing programs to count vowels, sort words in files, find common letters in strings, sort lists by vowel count, create classes to represent people and circles, work with dictionaries, arrays, matrices, and create a basic calculator using tkinter.
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

PYTHON PROGRAMMING LAB

Lab INTERNAL 2 ( Lateral Entry Students)

Course Code: 19CT1106 Date of Exam:

List of Experiments:

1. A) Write a program to count the number of vowels in a string (No control flow allowed).
B) Write a program to sort words in a file and put them in another file. The output file should
have only lower case words, so any upper case words from source must be lowered. (Handle
exceptions)

2. A) Write a program that displays which letters are present in both strings.
B) Write a program to find the most frequent words in a text.(read from a text file)

3. A) Write a program to sort given list of strings in the order of their vowel counts.
B) Write a Python class named Person with attributes name, age, weight (kgs), height (ft) and
takes them through the constructor and exposes a method get_bmi_result() which returns one
of "underweight", "healthy", "obese".

4. A) Write a program to generate a dictionary that contains numbers (between 1 and n ) in the
form of (x, x*x).
B) Write a Python class named Circle constructed by a radius and two methods which will
compute the area and the perimeter of a circle.

5. A) Write a program to check if a given key exists in a dictionary or not.


B) Write a program to create, display, append, insert and reverse the order of the items in the
array.

6. A) Write a program to add a new key-value pair to an existing dictionary.


B) Write a program to add, transpose and multiply two matrices

7. A) Write a program to sum all the items in a given dictionary.


B) Write a program to sort words in a file and put them in another file. The output file should
have only lower case words, so any upper case words from source must be lowered. (Handle
exceptions)

8. Write a program to create a basic calculator using tkinter.

9. A) Write a program to sum all the items in a given dictionary.


B) Write a program to find the most frequent words in a text.(read from a text file)

10. A) Write a program to add a new key-value pair to an existing dictionary.


B ) Write a Python class named Person with attributes name, age, weight (kgs), height (ft)
and takes them through the constructor and exposes a method get_bmi_result() which returns
one of "underweight", "healthy", "obese".

11. A) Write a program to check if a given key exists in a dictionary or not.


B) Write a Python class named Circle constructed by a radius and two methods which will
compute the area and the perimeter of a circle.

12. A) Write a program to generate a dictionary that contains numbers (between 1 and n ) in the
form of (x, x*x).
B) Write a program to create, display, append, insert and reverse the order of the items in the
array.

13. A) Write a program to sort given list of strings in the order of their vowel counts
B) Write a program to add, transpose and multiply two matrices

14. A) Write a program that displays which letters are present in both strings.
B) Write a program to count the number of vowels in a string (No control flow allowed).

15. Write a program to create a basic calculator using tkinter

You might also like