Go: package main

import (
    "os"
    "fmt"
    "bufio"
    "strconv"
)

var sc = bufio.NewScanner(os.Stdin)
func readInt() int64 {
    sc.Scan()
    n, _ := strconv.Atoi(sc.Text())
    return int64(n)
}


func main() {
    var ans int64 = 1
    var n int64 = readInt()
    var i int64
    for i = 1; i <= n; i++ {
        ans *= i
    }
    fmt.Println(ans)
}

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;
long long 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>
#include <stdio.h>
using namespace std;
int main(){
    int n;
    double x=1;
    cin >> n;
    for (int i=1;i<=n;i++){
        x*=i ;
    }
    // cout << x << endl;
    printf("%.0f",x);
}

C++: nclude<iostream>
using namespace std;
int function(int n){
  if(n > 1)
    return n * function(n-1);
  else
    return 1;
}

int main(){
  int n;
  cin >> n;
  cout << function(n) << endl;

}

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

C++: #define scanf_s scanf
//#define gets_s gets
#include <stdio.h>
#include <string>
#include <iostream>
#include <math.h>
using namespace std;
#define MAX 81
#define _MAX 100
#define ABC 26
int main(void)
{
	int n;
	long long int ans = 1;
	scanf_s("%d", &n);
	for (int i = 1; i <= n; ++i) {
		ans *= i;
	}
	printf("%lld\n", ans);
}

C++: #include<bits/stdc++.h>
using namespace std;
int main(){
    long long i=1,n;
    scanf("%lld",&n);
    while(n!=0){
        i*=n;
        n--;
    }
    printf("%lld\n",i);
    return 0;
}

C++: #include <iostream>
#include <cmath>

using namespace std;

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

C++: #include <stdio.h>

int main()
{
  long long int i, n;
   long long int fact = 1;
  scanf("%lld", &n);

  for (i = 1; i <=n; i++)
    fact = fact * i;

  printf("%lld", fact);

  return 0;
}

C++: #include <iostream>

using namespace std;

int main() {
	int n;
	int re = 1;
	cin >> n;
	while(n >= 2) {
		re *= n;
		n--;
	}
	
	cout << re << endl;
	
	return 0;
	
}

C++: #include <stdio.h>

int main()
{
  long long int n;
  int i, fact = 1;
  scanf("%lld", &n);

  for (i = 1; i <=n; i++)
    fact = fact * i;

  printf("%lld", fact);

  return 0;
}

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

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

C++: #include<iostream> 

using namespace std;

// int型に収まりきらないので変えた。
// 正しい型を書くのが面倒になったのでテンプレートで型推論させる。
template<typename T>
T func(T x) {
	return x <= 1 ? 1 : x * func(x - 1);
}

int main() {
	long long n;

	cin >> n;

	cout << func(n) << endl;

	return 0;
}

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

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

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

int main(){
  long long a[21],b;
  a[1]=1;
  for(int i=2;i<20;i++)a[i]=a[i-1]*i;
  cin>>b;
  cout<<a[b]<< endl;
  return 0;
}

C++: #include <stdio.h>

int fac(int n)
{
    int i,f=1;
    for(i=2;i<=n;i++)
    {
        f*=i;
    }
    
    return f;
}

int main(void)
{
    int n;
    
    scanf("%d",&n);
    printf("%d\n",fac(n));
    
    return 0;
}

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

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

C++: #include<iostream>



int input=0;

void factorial(int& i__)
{
	int result=1;
	for(int i=i__;i>0;i--)
	{
		result*=i;
	}

	std::cout<<std::endl<<result<<std::endl;

}

int main()
{
	while(input>20)
	{	
		std::cin>>input;
		factorial(input);
	}


	return 0;
}

C++: #include <iostream>

unsigned long long Fact(unsigned long long n);

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


	while (std::cin >> n)
	{
		ans = Fact(n);

		std::cout << ans << std::endl;
	}
}

unsigned long long Fact(unsigned long long n)
{
	if (n == 1)
		return 1;
	else
		return n * Fact(n - 1);
}

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

int main(void){
    long n, x;
    cin >> n;
    x = 1;
    while(n != 1){
        x *= n;
        n--;
    }
    cout << x << endl;

    return 0;
}

C++: #include <iostream>
#include <cstdio>
#include <vector>
#include <list>
#include <algorithm>
#include <cmath>
#include <stack>
#include <set>
using namespace std;

#define REP(i,n) for(int (i)=0; (i)<(n); (i)++)
#define FOR(i,a,b) for(int (i)=(a); (i)<(b); (i)++)
#define PUSH(n,v) for(int i=0; i<(n); i++) {int j; cin >> j; v.push_back(j);}
#define ALL(v) v.begin(), v.end()

long factorial(long n) {
    if (n == 1) return 1;
    else return n * factorial(n-1);
}

int main() {
    int d;
    cin >> d;
    cout << factorial(d) << endl;
    return 0;
}

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

int fac(long long x) {
	if (x == 0ll)
	{
		return 1;
	}
	else
	{
		return x*fac(x - 1);
	}
}

int main()
{
	long long n;
	cin >> n;
	cout << fac(n) << endl;
}

C++: #include<iostream>
 #include<cstdio>
  using namespace std;
  int fact(int n1){
    if (n1==0)
    return 1;
    else 
    return n1*fact(n1-1);
}
 int main(void)
 {
     int n;
    scanf("%d",&n);

       printf("%d\n",fact(n));

          return 0; }

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

int main () {
    int n, a=1,i;
    cin >> n:
    for(i=n;i>1;i--) {
        a *= n;
    }
    cout << a << endl;
}

C++: p (1..gets.to_i).inject(:*)