0% found this document useful (0 votes)
4 views5 pages

Python Program Question List for PR Exam

The document contains a list of practical Python programming exercises covering various topics such as displaying messages, using operators, conditional statements, loops, data structures (lists, tuples, sets, dictionaries), classes, inheritance, and working with the pandas library. Each practical task includes specific requirements for the program to be written, such as creating functions, manipulating data, and implementing object-oriented programming concepts. The exercises are designed to enhance programming skills and understanding of Python fundamentals.

Uploaded by

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

Python Program Question List for PR Exam

The document contains a list of practical Python programming exercises covering various topics such as displaying messages, using operators, conditional statements, loops, data structures (lists, tuples, sets, dictionaries), classes, inheritance, and working with the pandas library. Each practical task includes specific requirements for the program to be written, such as creating functions, manipulating data, and implementing object-oriented programming concepts. The exercises are designed to enhance programming skills and understanding of Python fundamentals.

Uploaded by

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

Python Program Question List

1. Practical NO 2: Write simple Python program to display message on


screen

Write a Python program to display Your name , age and City On the Screen.
(Take input from the user).

2. Practical NO 3: Write simple Python program using operators: Arithmetic


Operators, Logical Operators, Bitwise Operators
A) Write a program to find the square root of a number.
B) Write a program to swap the value of two variables.

3. Practical NO 4: Write simple Python program to demonstrate use of


conditional statements: if’ statement, ‘if … else’ statement, Nested ‘if’
statement.

A) Write a program to check if the input year is a leap year of not


B) Write a program to check if a Number is Positive, Negative or Zero

4. Practical NO 4: Write simple Python program to demonstrate use of


conditional statements: if’ statement, ‘if … else’ statement, Nested ‘if’
statement.

Write a program that takes the marks of 5 subjects and displays the grades.

5. Practical NO 5: Write Python program to demonstrate use of looping


statements: ‘while’ loop, ‘for’ loop and Nested loop

Write a Python program to print all even numbers between 1 to 100 using while
loop.

6. Practical NO 5: Write Python program to demonstrate use of looping


statements: ‘while’ loop, ‘for’ loop and Nested loop
Write a python program to find Fibonacci series for given number.

7. Practical No 6: Write Python program to demonstrate use of loop control


statements: continue, pass, break

Describe pass with example.


Write program to demonstrate use of continue. (Print 1 TO 10 numbers ,
skipping 5)

8. Practical No 7: Write Python program to perform following operations on


Lists: Create list, Access list, Update list (Add item, Remove item), and
Delete list

- Create List With Items


- Display List
- Insert an element at 5 index
- Insert an element at Last index
- Update an element at index 3 in a list
- Remove an element from list at index 8

9. Practical No 8: Write python program to use built-in functions/methods on


list: cmp, len, max, list, append, count, extend, insert, pop, remove, etc.

- Create List And display


- Write a Python program to sort a list.
- Extract the last 4 elements from the list using slicing.
- Using extend Combine two list

10. Practical No. 9: Write python program to perform following operations on


tuple: Create, Access, Print, Delete & Convert tuple into list and vice-
versa

- Create Tuple with Items


- Display Tuple
- Insert an element in tuple
- Delete an element from tuple
- Display updated tuple
- Combine Two tuple
11. Practical No. 10: Write python program to perform following operations
on the Set: Create set, Access Set, Update Set, Delete Set

- Write a Python program to create a set, add member(s) in a set and remove
one item from set and Display.
- Write a Python program to find maximum and the minimum value in a set.
- Write a Python program to find the length of a set.

12. Practical No. 11: Write python program to perform following functions on
Set: Union, Intersection, Difference, Symmetric Difference

- Write a Python program to perform following operations on set: intersection of


sets, union of sets, set difference, symmetric difference, clear a set.

- Difference between set & tuple.

13. Practical No. 12: Write python program to perform following operations
on the Dictionary: Create, Access, Update, Delete, Looping through
Dictionary, Create Dictionary from list

- Write a Python script to concatenate following dictionaries to create a new


one.
Sample Dictionary:
dic1 = {1:10, 2:20}
dic2 = {3:30, 4:40}
dic3 = {5:50, 6:60}

- Write Python Program to create dictionary and insert one item , delete one
item and update one item and display .

14. Practical No. 20: Develop a python program to perform following


operations: 1.Creating a Class with method 2.Creating Objects of class 3.
Accessing method using object

- Write a Python class that has two methods: get_String and print_String ,
get_String accept a string from the user and print_String prints the string in
upper case.

15. Practical No. 20: Develop a python program to perform following


operations: 1.Creating a Class with method 2.Creating Objects of class 3.
Accessing method using object
- Write a Python class named Rectangle constructed from length and width and
a method that will compute the area of a rectangle.

16. Practical No. 22: Implement a python program to demonstrate


1. Method Overloading 2. Method Overriding

- Write a Python program to create a class to print the area of a square and a
rectangle. The class has two methods with the same name but different
number of parameters. The method for printing area of rectangle has two
parameters which are length and breadth respectively while the other method
for printing area of square has one parameter which is side of square.

17. Practical No. 22: Implement a python program to demonstrate


2. Method Overloading 2. Method Overriding

- Write a Python program to create a class 'Degree' having a method


'getDegree' that prints "I got a degree". It has two subclasses namely
'Undergraduate' and Postgraduate' each having a method with the same
name that prints "I am an Undergraduate" and "I am a Postgraduate"
respectively. Call the method by creating an object of each of the three
classes.

18. Practical No. 24: Write a python program to implement Single inheritance
2. Multiple Inheritance 3. Multilevel inheritance

- Write Python program to read and print students information using Multilevel
inheritance. (Accept Name from user in Base Class, Accept Roll no from
user in first derived class and Accept Marks from User in Third Derived
Class. And this All info display in Third Derived Class using Method
Display())

19. Practical No. 25: Implement Python program to perform following


operations using panda package: 1. Create Series from Array 2. Create
Series from List 3. Access element of series 4. Create DataFrame using
List or dictionary
- Write a Python program to create series from array using Panda.
- Write a Python program to create series from list using Panda.
- Write a Python program to access element of series using Panda.
- Write a Python program to create DataFrame using list or dictionary using
Panda.

20. Practical No. 26: Implement python program to load a CSV file into a
Pandas DataFrame and perform operations.

- Write a Python program to read and write with CSV files using pandas.

21. Practical No. 28: Write python GUI program that adds labels and buttons
to the Tkinter window

- Write GUI program to import Tkinter package and create a window and set its
title, add labels and button to the tkinter window.

22. Practical No. 15: Write Python program to demonstrate use of following
advanced functions: lambda, map, reduce

- What is the purpose of the lambda(), map(), reduce() function in Python?


(explain with example of each)

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy