Python Program to Display the multiplication Table

In this tutorial you will learn to write a simple Python Program to Display the multiplication Table for the number entered by the user.

Source code to display multiplication table

Python example program

1 # Python Program to display multiplication table
2 
3 # take input from the user
4 number = int(input("Display multiplication table for the number : "))
5 
6 # iterate from 1 to 20 and display the table
7 for i in range(1, 21):
8    print(number, 'x', i, '=', number*i)

Program Output : Run 1

Display multiplication table for the number : 6

6 x 1 = 6

6 x 2 = 12

6 x 3 = 18

6 x 4 = 24

6 x 5 = 30

6 x 6 = 36

6 x 7 = 42

6 x 8 = 48

6 x 9 = 54

6 x 10 = 60

6 x 11 = 66

6 x 12 = 72

6 x 13 = 78

6 x 14 = 84

6 x 15 = 90

6 x 16 = 96

6 x 17 = 102

6 x 18 = 108

6 x 19 = 114

6 x 20 = 120