int(input):-
1. Write a program to input two numbers and find out their sum and
product.
2. Write a program to input the length and breadth of the rectangle and
calculate the area.
3. Write a program to input principle, rate of interest and time,
calculate the simple interest.
4. Write a program to find the area and perimeter of the circle.
5. Write a program to find square and cube of numbers.
6. Write a program to find average of marks in 5 subjects with name.
7. Write a program to find out the selling price of a product, cost price
and profit have to be expected by the user.
8. Write a program to convert given time (in minutes) into hours and
minutes.
9. Write a program to find out the total time taken by a student who is
travelling 450 km with average speed.
if statements:-
1. Write a program to input a person's age and check whether he is
eligible to vote or not.
2. Write a program to input your name and percentage. If the
percentage is greater than 50, print pass, otherwise print fail.
3. Write a program to input cost price and selling price of a product.
Calculate profit and if profit is more than 50, print any message.
4. Write a program to input name and three subject marks. Calculate
percentage, if percentage>70, print Grade A else print Grade B.
5. Write a program to enter a number and check whether it is an even
or odd number.
if-elif:-
1. Write a program to input the percentage of students and give the
grade accordingly.
Percentage>80 = A
70<Percentage<80 = B
60<Percentage<70 = C
50<Percentage<60 = D
Else=E
2. Write a program to accept salary from the user and calculate the tax
according to given conditions.
Salary<=50000, Tax 5%
Salary<=60000, Tax 7%
Salary<=70000, Tax 8%
Else, Tax 10%
Nested if-elif:-
1. Write a program to input a number and check whether it is positive
or negative.
Menu Driven Program:-
1. Write a program to make a menu with the following choices.
1) Addition
2) Subtraction
3) Multiplication
4) Division
2. Prepare a menu driven of the following.
1) Area of Circle
2) Circumference of Circle
3) Area of Rectangle
For Loop:-
1. Write a program using range to print counting from 1 to 100.
2. Write a program to print the table of any number.
3. Write a program to print all the even numbers lying between 2 to
100.
4. Write a program to print all the odd numbers lying between 1 to 100.
5. Write a program to find the sum of all the natural numbers up to 100.
While Loop:-
1. Write a program to display the Fibonacci Series.
2. Write a program to print counting from 1 to 100 using while loop.
3. Write a program to print sum of all even numbers lying between 1 to
100.
4. Write a program to check whether the entered number is a
Palindrome number or not.
5. Write a program to check whether the entered number is an
Armstrong number or not.
6. Write a program to print even numbers between 1 to 100.
7. Write a program to print the table of a no. using while loop.
8. Write a program to input name, marks in 3 subjects and calculate the
percentage. Program should run for three students.
Nested Loop:-
1. Write a program to print a pattern.
2 2 2
2 2 2
2 2 2
2. Write a program to print a pattern.
5 5 5 5
5 5 5 5
5 5 5 5
3. Write a program to print the following pattern.
1 2 3
1 2
1
4. Write a program to print the following pattern.
A
B C
D E F
G H I J
K L M N O
5. Write a program to print the following patterns.
(i)
1
1 2
1 2 3
1 2 3 4
1 2 3 4 5
(ii)
1
3 3
5 5 5
7 7 7 7
9 9 9 9 9
(iii)
5
4 5
3 4 5
2 3 4 5
1 2 3 4 5
Jump Statements:-
1. Write a program to take a 'string' and if it encounters 'i' in 'string', it
should come out of the loop.
2. Write a program to print numbers from 1 to 10 and if the number
value becomes 5, it should come out of the loop.
3. Write a program to find out the sum of all positive numbers entered
by the user and if the number is negative, the loop should stop and
show the calculated sum.