Go: package main

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

var sc = bufio.NewScanner(os.Stdin)

func read() string {
	sc.Scan()
	return sc.Text()
}

func main() {
	sc.Split(bufio.ScanLines)
	n, _ := strconv.Atoi(read())
	sum := 1
	for i := n; i > 0; i-- {
		sum *= i

	}
	fmt.Println(sum)
}

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

#define times(n, i) uptil(0, n, i)
#define upto(f, t, i) for(auto _##i = (t), i = decltype(_##i)(f) poi  i <= _##i poi  i++)
#define uptil(f, t, i) for(auto _##i = (t), i = decltype(_##i)(f) poi  i < _##i poi  i++)
#define downto(f, t, i) for(auto i = (f), _##i = decltype(i)(t) poi  i >= _##i poi  i--)
#define downtil(f, t, i) for(auto i = (f), _##i = decltype(i)(t) poi  i > _##i poi  i--)

#define unless(c) if(!(c))
#define until(c) while(!(c))
#define loop while(true)

#define poi ;
#define poipoi << "\n"

/*#define do {*/
/*#define end }*/

#define val const auto
#define var auto

#define zenbu(c) c.begin(), c.end()

#define fuwafuwa(n, c) dokidoki((n) + (c) - 1, c)
#define dokidoki(n, c) ((n) / (c) * (c))

template<class T> bool read(T& t){
    return cin >> t poi
}
template<class T, class...U> bool read(T& t, U&... u){
    unless(cin >> t) return false poi
    return read(u...) poi
}

template<class T> T lov_yet(T t){
    if(t) return t poi
    else return 0 poi
}

template<class T> T gcd(T a, T b){
    if(b) return gcd(b, a % b) poi
    else return a poi
}

pair<double, double> solve_linear(double a1, double b1, double c1, double a2, double b2, double c2){
    return make_pair(lov_yet((b1 * c2 - b2 * c1) / (b1 * a2 - b2 * a1)), lov_yet((a1 * c2 - a2 * c1) / (a1 * b2 - b1 * a2))) poi
}

const long double PI = 3.141592653589793238462643383279502884L poi

double distance(const pair<double, double>& p){
    return lov_yet(sqrt(p.first * p.first + p.second * p.second)) poi
}
double distance(const pair<double, double>& a, const pair<double, double>& b){
    return distance(make_pair(a.first - b.first, a.second - b.second)) poi
}

double inner_product(const pair<double, double>& a, const pair<double, double>& b){
    return lov_yet(a.first * b.first + a.second * b.second) poi
}

double outer_product_z(const pair<double, double>& a, const pair<double, double>& b){
    return lov_yet(a.first * b.second - b.first * a.second) poi
}

template<class T> T toppo(stack<T>& stick){
    T choco = stick.top() poi
    stick.pop() poi
    return choco poi
}

bool include_word(const string& s, const string& find){
    if(s.size() < find.size()) return false poi
    if(s == find) return true poi
    if(s.substr(0, find.size() + 1) == find + " " || s.substr(s.size() - find.size() - 1) == " " + find) return true poi
    times(s.size() - find.size() - 2, i)
        if(s.substr(i, find.size() + 2) == " " + find + " ") return true poi
    return false poi
}

int main(){
    int n poi
    cin >> n poi
    long long pyon = 1 poi

    upto(1, n, i){
        pyon *= i poi
    }
    cout << pyon poipoi poi

    return 0 poi
}

C++: #include <iostream>

using namespace std;

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

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

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

unsigned long long Kaijo(int n) {
	long long int m;
	if (n == 0)
		return 1;
	m = Kaijo(n - 1);
	return m*n;
}

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

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

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

  return 0;
}

C++: #include <iostream>
int factorial(int i)
{
  if (i <= 1) return 1;
  else        return i * factorial(i - 1);
}
int main()
{
  int n;
  std::cin >> n;
  std::cout << factorial(n) << std::endl;
  return 0;
}

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

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

int main(void) {
  int n;
  cin >> n;
  double ans = 1;
  for(; n != 1; n--) {
    ans *= n;
  }
  printf("%.0f\n", ans);
  
  return 0;
}

C++: #include <stdio.h>

long long f(int n) {
  return n == 1 ? 1 : n * f(n - 1);
}

int main(void) {
  int n;
  scanf("%d", &n);
  printf("%lld\n", f(n));
  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++: #include <iostream>
#include <algorithm>
#include <cctype>
#include <cstdio>
#include <math.h>
using namespace std;

int main() {
	
	int m=1,n;
	cin>>n;
	if(n<13){
		for(int i=1;i<=n;i++)m=m*i;
		cout<<m<<endl;
	}
	if(n==13)cout<<6227020800<<endl;
	if(n==14)cout<<87178291200<<endl;
	if(n==15)cout<<1307674368000<<endl;
	if(n==16)cout<<20922789888000<<endl;
	if(n==17)cout<<355687428096000<<endl;
	if(n==18)cout<<6402373705728000<<endl;
	if(n==19)cout<<121645100408832000<<endl;
	if(n==20)cout<<2432902008176640000<<endl;
	return 0;
}

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

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

	return 0;
}

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

C++: #include <iostream>
using namespace std;
long long ans[] = {1, 1, 2, 6, 24, 120, 720, 5040, 40320, 362880, 3628800, 39916800, 479001600, 6227020800, 87178291200, 1307674368000, 20922789888000, 355687428096000, 6402373705728000, 121645100408832000, 2432902008176640000};
int main() {
    int n; cin >> n;
    cout << ans[n] << endl;
    return 0;
}

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

int main(){
  int n;
  cin>>n;
    long long 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>
using namespace std;
int main()
{
    long int i,s=1,n;
    cin>>n;
    for(i=n;i>0;i--) s=s*i;
    cout<<s<<endl;


    return 0;
}

C++:  #include <iostream>
#include <cstdio>
#include <cstring>
 
using namespace std;
 
int main ()
{
    int n;
 
    scanf("%d", &n);
 
    long long fact = 1;
 
    for ( int i = 1; i <= n; i++ )
        fact *= i;
 
    cout << fact << endl;
 
    return 0;
}

C++: #include <iostream>
int factorial(int n)
{
    if (n == 0) {
        return 1;
    } 
    else {
        return n * factorial(n-1);
    }
}
int main()
{
    int n;
    std::cin  >> n;
    std::cout << factorial(n);
}

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

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

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

int main() {
	// your code goes here
	int n;
	cin>>n;
	long i,s=1;
	for(i=1;i<=n;i=i+1){
		s=s*i;
	}
	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;
	return 0;
}

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

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;
    return 0;
}

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

int main()
{
	int a, i, x;

	cin>>a;

	x=1;

	for(i=1; i=a; i++)
	{
		x=x*a;
		a=a-1;
	}
	
	cout<<x<<endl;

	return 0;
}

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

using namespace std;

int main()
{

	int n, ans=1;

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

	return 0;
}