'''
using while loop
'''
# num = 8
# result = 8
# while num > 1:
#     result = result * (num-1)
#     num -= 1
# print(result)
'''
using for loop
'''
result = 1
for i in range(2, 9):
    result *= i

print(result)

'''
using recursive
'''
# def fact(num):
#     if num == 0:
#         return 1
#     return num * fact(num-1)


# print(fact(8))
