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 <iostream>
using namespace std;

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

C++: #include<stdio.h>
#include<string.h>
int main()
{
    int a,ans;
    double p;
    while(scanf("%d",&ans)==1)
    {
        p=1;
        for(a=2;a<=ans;a++)
            p = p*a;
        printf("%0.lf\n",p);
    }
}

C++: #include <cstdio>

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

int main(){
	int a;
	scanf("%d", &a);
	printf("%ld\n", fact(a));
	return 0;
}

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

using namespace std;

int main(){
    long long k=1;
    for(int i=1;i<=20;i++){
        k*=i;
    }
    cout<<k<<endl;
        return 0;
}

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

}

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

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

C++: #include <iostream>
#include <string>
#include <algorithm>
#include <utility>
#include <iomanip>
#include <functional>
#include <queue>
#include <stack>
#include <cmath>
#define INF 100000000
#define MOD 1000000007
using namespace std;


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

C++: #include <iostream>
#include <algorithm>
#include <functional>

using namespace std;

int main(int argc, char const* argv[])
{
	unsigned int n;
	int i;

	cin >> n;

	for( i = n,n = 1;i >= 1;i-- ) n *= i;

	cout << n << endl;

	return 0;
}

C++: #include <bits/stdc++.h>

using namespace std;

typedef long long ll;

#define FOR(i,a,b) for(int i=(a);i<(b);i++)
#define REP(i,a) FOR(i,0,a)

int main(){
	int n;
	cin>>n;
	ll fact=1;
	FOR(i,2,n+1){
		fact*=i;
	}
	cout<<fact<<endl;
	return 0;
}

C++: 
#include <iostream>
using namespace std;
int main(){
    int n,i,ans[20];
    cin>>n;
    for(i=0;i<=n;i++){
        if(i==0){
            ans[0]=1;
        }else{
            ans[i]=ans[i-1]*i;
        }
    }
    cout<<ans[n]<<endl;
    return 0;
}

C++: #include <iostream>
#include <string>
#include <algorithm>
#include <vector>
#include <math.h>
#include <numeric>

using namespace std;

long long int a(long long int x) {
	if (x == 1) {
		return 1;
	}
	return x * a(x - 1);
}

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

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

C++: #include <stdio.h>

int main(){
    int i,n;
    unsigned long long f=1;
    scanf("%d",&n);
    for(i=2;i<=n;i++){
        f*=i;
    }
    printf("%lld\n",f);
}

C++: #include <iostream>

using namespace std;

int main(){
	long long int list[21];
	list[0]=1;
	int n;
	cin >> n;
	for(int i=1;i<=n;i++)
		list[i]=list[i-1]*i;
	cout << list[n] << endl;
	return 0;
}

C++: #include <iostream>
#include <vector>
#include <string>
#include <stack>
#include <queue>
#include <deque>
#include <set>
#include <map>
#include <algorithm>	// require sort next_permutation count __gcd reverse etc.
#include <cstdlib>	// require abs exit atof atoi 
#include <cstdio>		// require scanf printf
#include <functional>
#include <numeric>	// require accumulate
#include <cmath>		// require fabs
#include <climits>
#include <limits>
#include <cfloat>
#include <iomanip>	// require setw
#include <sstream>	// require stringstream 
#include <cstring>	// require memset
#include <cctype>		// require tolower, toupper
#include <fstream>	// require freopen
#include <ctime>		// require srand
#define rep(i,n) for(int i=0;i<(n);i++)
#define ALL(A) A.begin(), A.end()

using namespace std;

typedef long long ll;
typedef pair<int, int> P;
ll f[22];

int main()
{
//	cut here before submit 
//	freopen ("testcase.dat", "r", stdin );
	memset (f, 0LL, sizeof (f ) );
	f[0] = 1LL;
	f[1] = 1LL;
	for (int i = 2; i <= 20; i++ ){
		f[i] = (ll)i*f[i-1];
	} // end for
/*
	rep (i, 21 ){
		cout << f[i] << endl;
	} // end rep
*/
	string str = "";
	while (getline (cin, str ) ){
		stringstream ss (str );
		int n;
		ss >> n;
		cout << f[n] << endl;
	} // end loop
		
	return 0;
}

C++: #include <iostream>

unsigned fact(unsigned int n)
{
    if (n <= 1) return 1;
    else return n * fact(n - 1);
}

int main()
{
    unsigned n;
    std::cin >> n;
    std::cout << fact(n) << std::endl;
}

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

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

	cin >> n;
	for (int i = 1; i <= n; i++) ans *= i;
	cout << ans << endl;

	return 0;
}

C++: #include <iostream>
#include <string>
#include <algorithm>
#include <cstdio>
#include <vector>
#include <cmath>
#include <stack>
#define REP(i, n) for(int i = 0;i < n;i++)
#define REPR(i, n) for(int i = n;i >= 0;i--)
using namespace std;

void factorial(int n){
	int fact[10] = {0};
	fact[0] = 1;
	for(int i=1; i<=n; i++){
		REP(j, 10){
			fact[j] *= i;
		}
		REP(j, 9){
			fact[j+1] += fact[j] / 10000;
			fact[j] -= (fact[j] / 10000) * 10000;
		}
	}
	int i;
	for(i=9; i >= 0; i--) {
		if (fact[i] != 0) {
			printf("%d", fact[i]);
			i--;
			break;
		}
	}
	while (i >= 0) {
		printf("%04d", fact[i]);
		i--;
	}
	cout << endl;
}

int main(){
    int n;
    cin >> n;
    factorial(n);
}

C++: //14
#include<iostream>

using namespace std;

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

C++: //#define __USE_MINGW_ANSI_STDIO 0
#include <bits/stdc++.h>

using namespace std;
typedef long long ll;
typedef vector<int> VI;
typedef vector<VI> VVI;
typedef vector<ll> VL;
typedef vector<VL> VVL;
typedef pair<int, int> PII;

#define FOR(i, a, n) for (ll i = (ll)a; i < (ll)n; ++i)
#define REP(i, n) FOR(i, 0, n)
#define ALL(x) x.begin(), x.end()
#define IN(a, b, x) (a<=x&&x<b)
#define MP make_pair
#define PB push_back
#define MOD 1000000007
#define INF (1LL<<30)
#define LLINF (1LL<<60)
#define PI 3.14159265359
#define EPS 1e-12
//#define int ll

signed main(void)
{
	ll n;
	cin >> n;
	ll sum = 1;
	FOR(i, 1, n+1) sum *= i;
	cout << sum << endl;
	return 0;
}

C++: #include<stdio.h>
int main()
{
    long long int n,ans = 1;
    scanf("%lld",&n);
    for(int i = 0; i < n; i++)
    {
        ans = ans * (i + 1);
    }
    printf("%lld\n",ans);
    return 0;
}

C++: //0019 Factorial

//nツつェツ禿シツ療債つウツづェツづゥ(ツつスツつセツつオ0<=n<=20)nツづ個階ツ湘ヲツづーツ出ツ療債つケツづヲ

//20!ツづ絞ntツづ可つィツつウツづ慊づィツづ慊つケツづア

#include<iostream>
using namespace std;
int main(void)
{
	long long n;
	cin >> n;
	long long x = 1;
	while(n)
	{
		x *= n;
		n--;
	}
	cout << x << endl;
	return 0;
}

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

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