#include <iostream>
using namespace std;

int fact(int number) {
    long r=0;
    for(int i=number; i>=1; i--)
{
r = r*i;
}
return r;
}
 
int main() {

int num;
long result =0;

cin >> num;

result = fact(num);

cout<<result;

    
}