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++: #define _USE_MATH_DEFINES
 
#include <iostream>
#include <cstdio>
#include <algorithm>
#include <string>
#include <vector>
#include <math.h>

using namespace std;

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

int main(){
	int i;
	
	cin >> i;
	cout << fact(i) << endl;

	return 0;
}

C++: #include <iostream>

using namespace std;

long long fact(long long n);

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

	return 0;
}

long long fact(long long n){
	if (n < 2) {
		return 1;
	} else {
		return n * fact(n-1);
	}
}

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

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

C++: #include <iostream>

using namespace std;

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

int main() {
    int num;
    
    cin >> num;
    
    if(0 <= num && num <= 12)
        cout << fact(num) << endl;
    
    return 0;
}

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

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

	cin >> n;

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

	cout << ans << endl

	return 0;
}

C++: int main(a,i){
long long n=scanf("%d",&a);
for(i=0;i++<a;)n*=i;
printf("%llu\n",n);
return 0;
}

C++: #include <stdio.h>

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

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

C++: #include<stdio.h>
#include<iostream>
#include<math.h>
#include<algorithm>
#include<string>
#define pi 3.14159
using namespace std;

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

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

	

	return 0;
}

C++: #include<stdio.h>
#include<iostream>
#include<math.h>
#include<algorithm>
#include<string>
#define pi 3.14159
using namespace std;

long int fact(long int n) {
	long int m;
	if(n == 1) return 1;
	else {
		m =n * fact(n - 1);
		cout << m <<endl;
	}
}

int main() {
	long int n;
	cin >> n;
	fact(n);

	

	return 0;
}

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

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

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

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

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

int main(){

	int n;
	long long x;
	
	cin >> n;
	
	x = 1;
	for(int i=1; i<=n; i++){
		x *= i;
	}

	cout << x << endl;

	return 0;
}

C++: #include <stdio.h>
#include <iostream>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
typedef long long Int;

Int f(int n) {
    Int r = 1;
    rep (i, n) r *= i+1;
    return r;
}

int main() {
    int n;
    scanf("%d", &n);
    cout << f(n) << endl;
    return 0;
}

C++: #include <iostream>
using namespace std;
int main(void){
    // Here your code !
    int n,a=1;
    cin>>n;
    
    for(int i=1;i<=n;i++){
        a=a*i;
    }
    cout<<a<<endl;
}

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

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

C++: #include<stdio.h>

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

C++: #include <stdio.h>
int main()
{ int n, count;
unsigned long long int factorial=1;
while(scanf("%d",&n)==1)
{
     if ( n== 0)
     printf("1\n");
     else
     {
         for(count=1;count<=n;++count)
     { factorial=factorial*count;}
      printf("%llu\n",factorial);
      }
      }
      return 0;
       }

C++: #include <stdio.h>

int factrial(int n)
{
	int fac;
	
	if(n == 1){
		return (1);
	}
	
	else{
		fac = factrial(n - 1) * n;
		if(fac >= 0){
			return (fac);
		}
		else{
			return(-1 * fac);
		}
	}
}

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

C++: #include <iostream>
#include<string>
#include<math.h>
using namespace std;

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

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

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

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


int main(){
int a;
long long sum=1;
	cin>>a;
	for (int i = a; i > 0; --i) {
		sum*=i;
	}
cout<<sum;
}

C++: #include<iostream>

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

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

int main(){
int n,b=0;
bool a=false;
int ans[30];
ans[0]=1;
for(int i=1;i<30;i++){
ans[i]=0;}
cin>>n;
for(int i=2;i<n+1;i++){
for(int j=0;j<30;j++){
ans[j]*=i;
ans[j]+=b;
if(ans[j]<10)b=0;
if(ans[j]>=10){
b=(ans[j]-ans[j]%10)/10;
ans[j]%=10;
}
}
}
for(int i=29;i>-1;i--){
if(ans[i]!=0){
a=true;}
if(a){
cout<<ans[i];}}
cout<<endl;}

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 << endl;
}

C++: #include <iostream>

using namespace std;

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

C++: #define _USE_MATH_DEFINES
#include <iostream>
#include <sstream>
#include <cmath>
#include <algorithm>
#include <queue>
#include <stack>

typedef long long ll;
using namespace std;

ll fact(ll n)
{
	return n<=1 ? 1 : n*fact(n-1);
}

int main()
{
	ll n;
	scanf("%lld",&n);
	cout << fact(n) << endl;
}

C++: #include<iostream>
main(){long n,i;std::cin>>n;for(i=n;--n;)i*=n;std::cout<<i<<"\n";}

C++: #include <iostream.h>
#include <conio.h>
using namespace std;
int main()
{
	int n=0, fact=1;
	 cout<<"Enter a number:";
	 cin>>n;

	 for(int i=n; i>=1; i--)
     fact*=i;
	 cout<<"Factorial for the number is: "<<fact<<endl;
     getchar();


	system("pause");
	return 0;
}

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

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

	long long ans = n;
	while(--n >= 1){
		ans *= n;
	}
	cout << ans << endl;
}

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

int main(){
  int n;
  while(cin>>n){
    int c=1;
    if(n==0)c=0;
    else
      for(int i=n;i>0;i--)
	c*=i;
    cout<<c<<endl;

  }
  return 0;
}

C++: #include<iostream>
double input=0;

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

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

}

int main()
{
	std::cin>>input;
	while(input<=20&&input>=0)
	{	
		factorial(input);
		std::cin>>input;
	}


	return 0;
}

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

using namespace std;

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

	uint64_t f = 1;
	for (int i = 1; i <= n; ++i)
		f *= i;

	cout << f << endl;

	return 0;
}

C++: #include<cstdio>


using namespace std;
int main(void)
{
	int a;
	double b = 1;
	scanf("%d",&a);
	for(int i = 1;i<=a;i++)
	{
		b = b * a;
	}
	printf("%.0lf\n",b);
	return 0;
}

C++: #include<iostream>

using namespace std;

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