#include <bits/stdc++.h>
using namespace std;
int main(){
   int h=1,n,i=1;
   cin>>n;
   while(i<=n){
   	   h=h*i;
   	   i++;
   }
   cout<<h;
   return 0;
}

/**************************************************************
	Problem: 1004
	User: binzicheng1
	Language: C++
	Result: Accepted
	Time:15 ms
	Memory:2072 kb
****************************************************************/