Control C201B P64976


Statement
 

pdf   zip

The nn first lines of multiplication table of a natural number nn are given by nn multiplicated by one, two, three, …, until nn. For instance, being n=5n = 5 we have 5×1=55\times 1=5, 5×2=105\times 2=10, 5×3=155\times 3=15, 5×4=205\times 4=20, 5×5=255\times 5=25.

Your task is to write a program that reads a natural number nn and prints the nn first lines of its multiplication table.

Input

The input is a natural number nn.

Output

Your program must print the nn first lines of the multiplication table of nn, following the format of the instances.

Public test cases
  • Input

    5
    
    

    Output

    5 x 1 = 5
    5 x 2 = 10
    5 x 3 = 15
    5 x 4 = 20
    5 x 5 = 25
    
  • Input

    1
    

    Output

    1 x 1 = 1
    
  • Input

    0
    

    Output

    
            
                                
  • Input

    10
    

    Output

    10 x 1 = 10
    10 x 2 = 20
    10 x 3 = 30
    10 x 4 = 40
    10 x 5 = 50
    10 x 6 = 60
    10 x 7 = 70
    10 x 8 = 80
    10 x 9 = 90
    10 x 10 = 100
    
  • Information
    Author
    Professorat de P1
    Language
    English
    Translator
    Carlos Molina
    Original language
    Catalan
    Other languages
    Catalan
    Official solutions
    C++
    User solutions
    C C++ Java JavaScript Python