1.
Print Numbers from 1 to 10
Problem: Print all the numbers from 1 to 10 using a for loop.
2. Print Even Numbers
Problem: Print all even numbers between 1 and 20 using a for loop.
3. Print Odd Numbers
Problem: Print all odd numbers between 1 and 20 using a for loop.
4. Print Multiples of a Number
Problem: Take a number as input and print its first 10 multiples using a for loop.
5. Simple Number Pattern
Problem: Print the following number pattern using a for loop:
12
123
1234
6. Print Squares of Numbers
Problem: Print the square of numbers from 1 to 10 using a for loop. Example: 1, 4, 9, 16,
...
7. Calculate the Sum of Numbers
Problem: Calculate and print the sum of all numbers from 1 to n, where n is given by the
user.
8. Print a Simple Star Pattern
Problem: Print a simple star pattern using a for loop:
**
***
****
9. Count Backwards
Problem: Print numbers from 10 to 1 using a for loop.
10. Print Table of 5
Problem: Print the multiplication table of 5 using a for loop.