Header Ads

Multiplication Table in Python |1*2=2|

Table in Python

1*2=2

 2*2=4        

 3*2=6

 4*2=8

 5*2=10

 6*2=12

 7*2=14

 8*2=16

 9*2=18

 10*2=20

 

#___Source_Code__#

 

num=int(input("Which Table You Want To Print Type Here --> "))

for i in range (1,11):

        print (i,"x",num,"=",num*i)

 

Description:

 

num=int(input("Which Table You Want To Print Type Here --> "))  #Taking user`s input

for i in range (1,11):  #Using loop for repeating numbers from (1 to 11)

print (i,"x",num,"=",num*i)  #Here we are first of all print (i) which is used in loop for repeating numbers (1 to 10) then we print (x) means multiplication sign then printing (num) which is user input then we are printing  (= )that is sign like (x) in the last we are print( num*i) it means we are multiplying the user input with loop  repeated numbers.  It means (1*user input) for example user enter 2 it multiply with number 1 like this 1*2=2. Loop also increase the number which number it is have for repeating.


If you don’t know about loop then go to this link Loop in easy way: and learn about loop.

If you have any question about this program then comment me bellow I will reply soon.

Thanks for coming if you like this post then share with others friends…

For Other Programs links:

Table in C/C++ 

Diamond Shape in C/C++/Python

My YouTube Channel Link : Computer Knowledge

For other Source Code and other Interesting Programs visit this website: Programs 

No comments

Powered by Blogger.