Page 255 - AI Computer 10
P. 255
Pop Quiz Quiz
Pop
Name the following.
1. A loop used for definite number of iterations. _____________________________
2. A loop used for unknown number of iterations. _____________________________
3. A conditional statement used for only two conditions. _____________________________
AI Fun Zone 21s
21stt
21st
Centuryturytury
Century
Century Project-based Learning
Cen
Cen
Skills
Skills
Skills
1. Write a program in Python for creating a variable that accepts radius of a circle. Also make appropriate use
of conditional statements in a program to check whether the radius is even or not. If radius is even, display
the area of the circle, otherwise, display the circumference of the circle.
2. Write a program in Python to accept the age of a person, entered by the user, and check whether he/she is a
senior citizen or not a senior citizen. (Hint: a person is considered a senior citizen if he/she is above 60 years
of age)
3. Write a program in Python to check whether the entered number is divisible by 11 or not.
4. Write a program in Python to print the area of rectangle, if length value is greater than breadth value,
otherwise print area of square.
5. Write a program in Python to print the Fibonacci series for first ten elements. (The Fibonacci series is 1, 1, 2,
3, 5, 8, 13, 21, 34, 55, …)
6. Write a program in Python to print the following pattern:
6 6 6
6 6 6
6 6 6
7. Write a program in Python to display the following pattern:
* * * *
* * *
* *
*
8. Write a program in Python to add the odd numbers upto a given value, specified by the user, and print the
result.
9. Write a program in Python to find the first greatest and second greatest number from the three numbers
input by the user.
10. Write a program in Python to add all the integer values specified in a list and display the total value.
11. Write a program to calculate the simple interest by using the variable priniciple_amount and roi (rate of
interest) with time divided by 100.
12. Write a program to take an integer value and a float value and adding both of them.
13. Write a program to calculate surface area and volume of a cuboid by accepting the length, breadth, and
height from the user.
14. Write a program to create a list of 10 elements and delete 5 elements from it.
15. Write a program to find the sum of all numbers stored in a list.
121
121