//0019 Factorial

//nツつェツ禿シツ療債つウツづェツづゥ(ツつスツつセツつオ0<=n<=20)nツづ個階ツ湘ヲツづーツ出ツ療債つケツづヲ

//20!ツづ絞ntツづ可つィツつウツづ慊づィツづ慊つケツづア

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