0% found this document useful (0 votes)
108 views4 pages

L1 CS 11 2022 2023

The document provides 21 programming problems related to calculating areas and volumes of geometric shapes, averages, grades, salaries, shopping mall floors, cricket scores, and school blocks. The problems cover basic mathematical and logical operations in Python like input/output, arithmetic, conditionals, and string manipulation. They are designed to help students learn and practice basic Python programming concepts.

Uploaded by

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

L1 CS 11 2022 2023

The document provides 21 programming problems related to calculating areas and volumes of geometric shapes, averages, grades, salaries, shopping mall floors, cricket scores, and school blocks. The problems cover basic mathematical and logical operations in Python like input/output, arithmetic, conditionals, and string manipulation. They are designed to help students learn and practice basic Python programming concepts.

Uploaded by

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

Delhi Public School, R.K.

Puram Computer Science

1. Write a program in python to accept Length (in inches of type float) and Breadth (in inches of
type float) of a Rectangle.
Find and display (a) Area of the rectangle and (b) Perimeter of the rectangle.
2. Write a Python program to convert degree to radian.
Note : The radian is the standard unit of angular measure, used in many areas of mathematics. An
angle's measurement in radians is numerically equal to the length of a corresponding arc of a unit
circle; one radian is just under 57.3 degrees (when the arc length is equal to the radius).
Sample output:
Input degrees: 45
In Radians : 0.7857142857142857
3. Write a Python program to convert radians to degrees.
Sample Output:
Input radians: 2
In Degree : 114.54545454545455
4. Write a Python program to calculate the area of a trapezoid.
Note : A trapezoid is a quadrilateral with two sides parallel. The trapezoid is equivalent to the
British definition of the trapezium. An isosceles trapezoid is a trapezoid in which the base angles
are equal.
Sample Output:
Height of trapezoid: 10
Top Width : 12
Bottom Width : 18
Area is : 150.0
5. Write a Python program to calculate the area of a parallelogram.
Note : A parallelogram is a quadrilateral with opposite sides parallel (and therefore opposite
angles equal). A quadrilateral with equal sides is called a rhombus, and a parallelogram whose
angles are all right angles is called a rectangle.
Sample Output:
Length of base : 9
Height of parallelogram : 7
Expected Output: Area is : 63.0
6. Write a Python program to calculate volume and surface area of a Cylindrical Oil Container.
Also
(i) Calculate the price of painting this Cylindrical Oil Container, if the price for painting is Rs.
530 per square meter.
(ii) Maximum cost of Petrol, that can be stored in the cylindrical container, if the price of
petrol is Rs. 73 per litre . [Remember 1 mtr cube = 1000 litre]
Sample Output:
Height [in meters]: 5
Radius [in meters]: 3
Volume : 141.42857142857142 [meter cube]
Volume [Rounded to Decimals]: 141.43
Surface Area is: 150.85714285714286 [mtr sq]
Surface Area [Rounded to 2 Decimals]:150.86
Painting Charges [Rs.]: 79955.8
Cost of Petrol [Rs.]: 10324390.0

Programming Practical List 1 CScXI/2022_2023/01 #1/4


Delhi Public School, R.K.Puram Computer Science

7. Write a Python program to calculate volume and area of a sphere.


Sample Output:
Radius of sphere: 5
Surface Area: 314.2857142857143
Volume : 523.8095238095237

8. Write a program in to accept Qty of Fuel (in Litre) and Distance travelled (in KM) from the user,
calculate and display the Average of the Vehicle (i.e. KM per Litre).
9. Write a program in to accept Marks of 5 subjects (each out of 100), calculate and display
(a) Total Marks obtained (b) Average Marks
10. Write a program to allocate and display Block and Floor No on the basis of Customer Number.
Assuming there are 10 Blocks (‘A’ to ‘J’) with 5 floors (0 to 4) each and allocated to customers
sequentially as per their Customer Number. For example: Customer no 1 gets [Block A Floor 0],
Customer no 3 gets [Block A Floor 2], Customer no 7 gets [Block B Floor 1]
Note: This program has to be done only using arithmetic operations and type conversions
(i.e., with out use of if-else)
Hint: ASCII codes for ‘A’,’B’.. are 65,66,... & chr(65) in python is ‘A’
11. Write a program to calculate total collection of a PARKING area on the basis of number of vehicles
under each category entered by the user. Per vehicle amounts for each type of vehicle is as
follows: Bus Rs. 100 SUV Rs.40 CAR Rs.30 Two-Wheeler Rs.10
Sample Output:
Number of Buses : 10
Number of SUVs : 20
Number of Cars : 45
Number of Two-Wheelers : 120
Collection for Buses : 1000
Collection for SUVs : 800
Collection for Cars : 1350
Collection for Two-Wheelers: 1200
Total Collection : 4350
12. Write a program to accept Basic Salary (Basic) of employee from user and calculate the following:
(a) Dearness Allowance (DA) as 30% of Basic
(b) House Rent Allowance (HRA) as 25% of Basic
(c) Income Tax (IT) as 10% of Basic if Basic<50000 and 20% of Basic if Basic>=50000
(d) Total Salary (TSAL) as BASIC+DA+HRA
(e) Salary in hand (SALH) as TSAL-IT
13. Write a program to accept marks of English (ENG), marks of Maths (MAT), marks of Science (SCI)
each out of 100, calculate and display the following:
(a) Total Marks (TOT) as ENG+MAT+SCI
(b) Percentage of Marks (PER) as TOT/3
(c) Display Grade as ‘A’ if PER>50 ‘B’ if PER>0 and ‘C’ if PER=0
[without using if_else command]

Programming Practical List 1 CScXI/2022_2023/01 #2/4


Delhi Public School, R.K.Puram Computer Science

14. Write a program to accept the age of the individual and display a message "Allowed to get a
license to Drive" if Age entered by the user >=18 else display a message "Wait for x years to get a
Driving License". Here, x to be replaced with 18-Age years.
15. Write a program to accept the grade of a student out of ‘A’ to ‘F’ from the user and display the
range of marks on the screen as per the following table using if else.
Grade Marks Range
A 100-90
B 89-75
C 74-60
D 59-45
E 44-33
F 32-0
16. Write a program to accept marks of a student out of 100, find and display Grades ‘A’ to ‘F’ as per
the following grade table using if else.
Marks Range Grade
100 -90 A
89.9-75 B
74.9-60 C
59.9-45 D
44.9-33 E
32.9-0 F
17. Write a program to make a calculator application with the following operations:
(a) Accept values of two real numbers
(b) Accept arithmetic operation to be performed out of ‘+’,‘-’,‘*’,‘/’,‘%’
(c) Perform the desired arithmetic operation on two real number and display the result of
operation as selected by the user
18. Write a program to display the Floor for the various items in a SHOPPING MALL on the basis of Age
and Gender entered by user as per the following table:
Age Gender Floor
>=60 M 7
>=20 and <60 M 6
>=10 and <20 M 5
<10 M 4
>=58 F 3
>=18 and <58 F 2
>=10 and <18 F 1
<10 F 0
Sample Output 1:
Age : 45
Gender : F
Floor : 2
Sample Output 2:
Age : 18
Gender : M
Floor : 5

Programming Practical List 1 CScXI/2022_2023/01 #3/4


Delhi Public School, R.K.Puram Computer Science

19. Write a program to accept runs of three consecutive cricket matches, find and display the highest
and lowest runs.
Sample Output:
Match 1 Runs: 320
Match 2 Runs: 210
Match 3 Runs: 275
Highest Runs: 320 Lowest Runs : 210
20. Write a program to accept scores of five individual players, find and display top two scores.
Sample Output:
Scores
Player 1: 450
Player 2: 120
Player 3: 320
Player 4: 910
Player 5: 240
First Top Score: 910 Second Top Score: 450

21. Write a program to display the BLOCK of buildings in school allocated for a particular group of
students as per their class and stream entered by the user.
Class Stream Block
11 'S' F Block
11 'C' E Block
11 'H' D Block
12 'S' C Block
12 'C' B Block
12 'H' A Block
Sample Output:
Enter Class : 11
Enter Stream : H
Block : D Block
General Instructions:
i. Type the solutions of all the problems using Python Language on Python IDLE or
colab.research.google.com
ii. Type in the following on top of each of your program as comment lines
# --------------------------------------------------------------#
# List-Program No : L1-P1
# Developed By : Jhilmil Roy
# Date : 26-July-2022
# --------------------------------------------------------------#
iii. On successful execution with meaningful data, copy and paste the sample output at the bottom
of the program as comment lines.
iv. “Turn in” the softcopy of the programs as a single document in response to this assignment
submission with each program on separate pages. Once verified by the teacher, take out a
hardcopy of each program on separate pages from the printer and get them signed by the
respective computer teacher. Add all the printouts in the practical file and get the Index entry
also signed.
v. Recommended Font, “Courier New”, Style “Bold” Size “10” for all programs with single line
spacing. Default indentation 2 Character only.

Programming Practical List 1 CScXI/2022_2023/01 #4/4

You might also like