Go: package main

import (
        "fmt"
)

func main() {
        var n int
        fmt.Scanf("%d", &n)
        fmt.Println(fact(n))
}

func fact(n int) (f uint64) {
        if n < 2 {
                return uint64(1)
        } else {
                return fact(n-1) * uint64(n)
        }
}

C++: #include<iostream>
using namespace std;
int main() {
	int n;
	long long int x;
	x = 1;
	cin >> n;
	for (int i = 0;i < n;i++)
	{
		x=x*(n - i);
	}
	cout << x <<endl;

}

C++: #include <cstdio>

using namespace std;

int main() {
  int n;
  scanf("%d", &n);

  unsigned long p = 1;
  for (; n > 1; p *= n--) {}

  printf("%ld\n", p);
  return 0;
}

C++: #include <iostream>
using namespace std;

int main(){
	int N;
	cin>>N;
	int res=1;
	for(int i=1;i<=N;i++){
		res*=i;
	}
	cout<<res<<endl;
}

C++: #include<iostream>
using namespace std;
int main() {
int n;
cin>>n;
long long ans = 1;
for(long long i=1; i<=n; i++) ans *= i;
cout<<ans<<endl;
}

C++: #include<iostream>
using namespace std;
int main()
{
	int n;
	cin >> n;
	int i = 1;
	while (n >= 1) {
		i *= n;
		n--;
	}
	cout << i;

	return 0;
}

C++: #include <iostream>

using namespace std;

int main()
{
	int n;
	int a = 1;
	cin >> n;
	for(int i = n; i > 0; i--){
		a *= i;
	}

	cout << a << endl;

	return 0;
}

C++: #include<iostream>
using namespace std;
int main()
{
int n,ans=1;
cin >> n;
for(int i=1;i<=n;i++){
ans*=i;
}
cout << ans << "\n";
}

C++: #include <iostream>
using namespace std;
int main() {
	unsigned int n,s;
	cin >> n;
    s=1;
	for (n;n>0;n--) s*=n; 
	cout << s <<  endl;
	return 0;
	}

C++: #include<iostream>
#include<algorithm>
#include<vector>
#include<stack>
#include<queue>
#include<cstdio>
#include<climits>
#include<cmath>
#include<cstring>
#include<string>
#include<complex>
#include<iomanip>
 
#define EPS (1e-10)
using namespace std;
#define PI (3.1415926535)
 
long long f(int n){
    if(n == 1)return 1;
    return n*f(n-1);
}
 
int main(){
    int n;
    cin >> n;

    cout << f(n) << endl;
 
    return 0;
}

C++: #include<iostream>
using namespace std;
int main(){
  long long int n,solve = 1;
  cin >>n;
  for(int i=1; i<=n; i++)
    solve *= i;
  cout <<solve<<endl;
  return 0;
}

C++: #include<iostream>
#include<cstdio>
using namespace std;

int main(){
  int n,i,t=1;
  cin>>n; 
    for(i=1;i<=n;i++){
      t*=i;  
      }
	
   cout<<t<<endl;
  
  return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;
int serch(int n)
{
    if(n==2)return n;
    return n*serch(n-1);
}
int main()
{
    int n;
    cin>>n;
    n=serch(n);
    cout<<n<<endl;
}

C++: #include<iostream>
#include<string>
#include<cstdio>
#include<cstring>
#include<algorithm>
using namespace std;
int main(void){
	long long int a=1;
    int n;
    cin>>n;

	for(int i=1;i<=n;i++){
        a*=i;
	}
    cout<<a<<endl;

	return 0;
}

C++: #include<bits/stdc++.h>
#define rep(i,n)for(int i=0;i<n;i++)
using namespace std;
typedef long long ll;
typedef pair<int, int>P;

int main() {
	int n; cin >> n;
	ll ans = 1;
	for (int i = 1; i <= n; i++) {
		ans *= i;
	}
	cout << ans << endl;
	return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;

int main() {
    size_t input;

    cin >> input;

    if(input==0)
        input=1;
    else {
        for(size_t i=input-1; i>0; i--)
            input*=i;
    }

    cout << input;
}

C++: #include<iostream>
using namespace std;

main(){
   int i,n,r;
  r=1;
  cin>>n;
  for(i=1;i<=n;++i){
    r=r*i;
  }
 cout<<r<<endl;
}

C++: #include<stdio.h>
#include<iostream>
using namespace std;
int ke(long long int x)
{
    if(x == 1)return 1;
    else return x*ke(x-1);
}
int main()
{
    long long int a;
    cin >> a;
    printf("%d\n",ke(a));
    return 0;
}

C++: #include <iostream>
using namespace std;

int main()
{
	int n;
	int ans = 1;
	int num;

	cin >> n;

	for(int i = n+1; i>1; i--)
	{
		ans *= (i-1);
	}

	cout << ans << endl;

	return 0;
}

C++: #include <iostream>
using namespace std;
int main(){
    int n;
	cin >> n;
    long long int x = 1;
    for(int i=0; i<n; ++i){
		x = x*(i+1);
    }
    cout << x << endl;
	return 0;
}

C++: #include <iostream>

using namespace std;

int main()
{
	int i, n;
	int fact = 1;

	cin >> n;

	for (i = 2; i <= n; i++) {
		fact *= i;
	}

	cout << fact << endl;

	return 0;
}

C++: #include <stdio.h>
#include <iostream>
#include <stdlib.h>
#include <string.h>
#include <algorithm>
using namespace std;
#define f(i,n) for(i=1; i<=n;i++)
int main(){
    int s=1,n,i,a,b,k;
    char c;
    scanf("%d", &n);
    f(i,n)
        s=s*i;                   
    printf("%d", s);
    return 0;
}

C++: #include <stdio.h>

int
main(void)
{
	char line[80];
	int n;

	if (fgets(line, sizeof line, stdin)) {
		if (sscanf(line, "%d", &n) == 1) {

			long long r = 1;
			for (int i = 2; i <= n; i++) {
				r *= i;
			}
			
			printf("%lld\n", r);
		}
	}

	return 0;
}

C++: #include <iostream>

using namespace std;

int main(void) {
	long long int n, ans = 1;

	cin >> n;
	for (int i = 1; i <= n; i++) {
		if (n == 0) {
			ans = 1;
			break;
		}
		else {
			ans *= i;
		}
	}
	cout << ans << endl;
}

C++: /*#include<stdio.h>
#include<stdlib.h>
#include<iostream>
#include<string>
#include<vector>
#include<math.h>
#include<queue>
#include <algorithm>
#include<functional>
#include<cstdlib>
#include<cmath>


#define REP(i, n) for(int i = 0;i < n;i++)
#define REPR(i, n) for(int i = n;i >= 0;i--)
#define FOR(i, m, n) for(int i = m;i < n;i++)
#define FORR(i, m, n) for(int i = m;i >= n;i--)
#define CI cin >>
#define CO cout <<
#define E << endl;

using namespace std;

typedef pair<int, int> P;
typedef pair<long, long> LP;
typedef pair<int, P> PP;
typedef pair<long, LP> LPP;



int dy[] = { 0, 0, 1, -1, 0 };
int dx[] = { 1, -1, 0, 0, 0 };

int A = 0, B = 0, K = 0, T = 0, W = 0, N = 0, H = 0;
int n = 0;
double L = 0;
double S = 0;
double ar = 0, br = 0, cr = 0;
int answer = 0;

string C;
string sA, strB;
vector<vector<char>> map;
vector<double> num;
vector<string> str;

int sum = 0;

vector<int> value;
vector<int> weight;

int dp[110][10010];

int data_[210][2] = { -2 };

void input(void) {
	CI n;
	return;
}


int main(void) {
	input();
	double money = 100000;
	
	for (int i = 0; i < n; i++) {
		money *= 1.05;
	}
	
	if ((int)money % 1000 >= 500) {
		CO (int)(money - ((int)(money) % 1000) + 1000) E
	}
	else {
		CO (int)(money - ((int)(money) % 1000)) E
	}

	

	return 0;
}

*/

#include<stdio.h>
#include<stdlib.h>
#include<iostream>
#include<string>
#include<vector>
#include<math.h>
#include<queue>
#include <algorithm>
#include<functional>
#include<cstdlib>
#include<cmath>


#define REP(i, n) for(int i = 0;i < n;i++)
#define REPR(i, n) for(int i = n;i >= 0;i--)
#define FOR(i, m, n) for(int i = m;i < n;i++)
#define FORR(i, m, n) for(int i = m;i >= n;i--)
#define CI cin >>
#define CO cout <<
#define E << endl;

using namespace std;

typedef pair<int, int> P;
typedef pair<long, long> LP;
typedef pair<int, P> PP;
typedef pair<long, LP> LPP;



int dy[] = { 0, 0, 1, -1, 0 };
int dx[] = { 1, -1, 0, 0, 0 };

int A = 0, B = 0, K = 0, T = 0, W = 0, N = 0, H = 0;
int n = 0;
double L = 0;
double S = 0;
double ar = 0, br = 0, cr = 0;
int answer = 0;

string C;
string sA, strB;
vector<vector<char>> map;
vector<double> num;
vector<string> str;

int sum = 0;

vector<int> value;
vector<int> weight;

int dp[110][10010];

int data_[210][2] = { -2 };

void input(void) {
	CI n;
	return;
}


int main(void) {
	input();

	
	for (int i = n - 1; i > 1; i--) {
		n  *= i;
	}

	CO n E

	return 0;
}

C++: #include <iostream>

using namespace std;

int fact (int n)
{
	if (n == 0)
	return 1;
	
	return n * fact(n - 1);
}

int main()
{
	int n;
	int ans;
	
	cin >> n;
	
	
	cout << fact(n) << endl;
	
	return 0;
}

C++: #include <iostream>
#include<math.h>
#include<iomanip>
#include<vector>
#include<algorithm>
#include<functional>
using namespace std;

int main()
{
    int  a=0,b=0,i=0;
    cin >> a;
    b=1;
    for(i=0;i<a;i++){
        b=b*(i+1);
    }
    cout << b << endl;
return 0;

}