#include<bits/stdc++.h>

using namespace std;

int main ()
{
    long long x,y;
    y=1;

    cin>>x;

    if(1<= x <= 20)
    {
        for(int i = x; i>0; i--)
        {
            y*=i;
        }
        cout<<y<<endl;
    }

    return 0;
}

