Programming Tasks Day 2
Programming Tasks Day 2
Q1: Take 10 integers from keyboard using while loop and print their average value
on the screen.
Q2: Print multiplication table of 24, 50 and 29 using while loop.
Q3: Factorial of any number n is represented by n! and is equal to 1*2*3*....*(n-
1)*n. E.g.-
4! = 1*2*3*4 = 24
3! = 3*2*1 = 6
2! = 2*1 = 2
Also,
1! = 1
0! = 1
Write a program to calculate factorial of a number.
Q4: Print the following patterns using loop :
*
**
***
****
Q5: Write a Python program that finds the smallest number in a list and prints it.
Use a for loop with a break statement.