► Python Program to Display the Multiplication Table
Steps followed:
1. take input from user
2. use "for loop" to iterate the multiplication 10 times
3. print result
#Python Program to Display the Multiplication Table
# Taking an input from user
number = int(input ("Enter the number for which the user wants to print the multiplication table: "))
# We are using "for loop" to iterate the multiplication 10 times
print ("The Multiplication Table of: ", number)
for count in range(1, 11):
print (number, 'x', count, '=', number * count)
Enter the number for which the user wants to print the multiplication table: 7
The Multiplication Table of: 7
7 x 1 = 7
7 x 2 = 14
7 x 3 = 21
7 x 4 = 28
7 x 5 = 35
7 x 6 = 42
7 x 7 = 49
7 x 8 = 56
7 x 9 = 63
7 x 10 = 70