#include<iostream>
 #include<cstdio>
  using namespace std;
  int fact(int n1){
    if (n1==0)
    return 1;
    else 
    return n1*fact(n1-1);
}
 int main(void)
 {
     int n;
    scanf("%d",&n);

       printf("%d\n",fact(n));

          return 0; } 