#include <iostream>

constexpr int factorial(int n) // Everything here is known at compile time
{
    return n <= 1 ? 1 : (n * factorial(n - 1));
}

int main(void)
{
    int i;
    std::cin >> i;
	const int f = factorial(i); // I really can't guess this at compile time..
	std::cout << f << std::endl;
	return 0;
}