from math import factorial
while True:
    try:print(factorial(int(input())))
    except:break