#include <iostream>
using namespace std;

int main(){
    unsigned int num;
    unsigned long long factorial=1;
    cin >> num;
    for(;num > 0; num--){
        factorial *= num;
    }
    cout << factorial;
    return 0;
}