Newer
Older
bth_py_exercises / 1.2 / mult_table.py
@Pascal Syma Pascal Syma on 31 Aug 2021 383 bytes Completed 1.2
"""
Exercise 1.2 - Multiplication table
"""


#  Copyright (c) 2021. Pascal Syma. All rights reserved.

def mult_table(_n: int):
    """
    mult_table
    :param _n: Factor
    """
    for i in range(10):
        print(f'{i} * {_n} = {i * _n}')


if __name__ == '__main__':
    print('This program prints out a multiplication table.')
    mult_table(int(input('Enter a number: ')))