from math import factorial j = int(input()) if j==1: print("2") else: print(factorial(j))