#include <iostream> using namespace std; long long jiecheng(long long x){ if(x == 1) return 1; else return x * jiecheng(x - 1); } int main() { long long n; while(cin >> n){ cout << jiecheng(n) << endl; } }