int n = Convert.ToInt32(Console.ReadLine());
int sum = 1;
for (int j = 1; j < n+1; j++)
{ sum *= j ; }
Console.WriteLine(sum);