Go: package main
import (
	"fmt"
	"os"
	"strconv"
	"bufio"
)

var sc = bufio.NewScanner(os.Stdin)

func main(){
	for sc.Scan(){
		n := nextInt()
		cnt := 0
		for a:=0; a<=9; a++{
			for b:=0; b<=9; b++{
				for c:=0; c<=9; c++{
					for d:=0; d<=9; d++{
						if a+b+c+d==n{
							cnt++
						}
					}
				}
			}
		}
		fmt.Println(cnt)
	}
}

func next()string{
	//sc.Scan()
	return sc.Text()
}

func nextInt()int{
	a, _ := strconv.Atoi(next())
	return a
}

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

using _i64 = int64_t;
using _u64 = uint64_t;
using _f64 = double;

#define _for(i, start, end) for(_i64 i = (_i64)start; i < (_i64)end; ++i)
#define _rep(i, number) _for(i, 0, number)
#define _foreach(e, data) for(auto& e : data)
#define _all(data) data.begin(), data.end()

template<typename type>
_i64 _size(const type& data) { return static_cast<_i64>(data.size()); }
template<typename type, size_t size>
_i64 _size(const type (&)[size]) { return static_cast<_i64>(size); }

enum _flag : bool { able = true, disable = false };

struct _time {
    _time(_flag flag) { check = flag; if(!check) { return; } gettime(start); }
    ~_time() {
        if(!check) { return; }; gettime(end);
        _i64 elapse = chrono::duration_cast<chrono::milliseconds>(end - start).count();
        cout << endl << "Time: " << elapse << " ms" << endl;
    }
    private:
    using _timer = chrono::time_point<chrono::system_clock>;
    _timer start, end; bool check;
    void gettime(_timer& time) { time = chrono::system_clock::now(); }
};

struct _ini { _ini() { ios::sync_with_stdio(false); cin.tie(nullptr); } } _ini;

int main() {
    {
        _time time(disable);
        _i64 n, ans;
        while(cin >> n) {
            ans = 0;
            _rep(a, 10) {
                if(a > n) { break; }
                _rep(b, 10) {
                    if(a + b > n) { break; }
                    _rep(c, 10) {
                        if(a + b + c > n) { break; }
                        if(a + b + c <= n && n <= a + b + c + 9) { ++ans; }
                    }
                }
            }
            cout << ans << endl;
        }
    }
    return 0;
}

C++: #include <cstdio>

int main() {
    int n;
    while ( scanf("%d", &n) != EOF ) {
          int x = 0;
          for (int a = 0; a < 10; a++) {
              for (int b = 0; b < 10; b++) {
                  for (int c = 0; c < 10; c++) {
                      for (int d = 0; d < 10; d++) {
                          if ( (a + b + c + d) == n ) {
                               x++;
                          }
                      }
                  }
              }
          }
          printf("%d\n", x);
    }
    return 0; 
}

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

using namespace std;

int main(){
int n;int ans(0);
cin>>n;
for(int i=0;i<=9;i++){
	for(int j=0;j<=9;j++){
		for(int k=0;k<=9;k++){
			for(int l=0;l<=9;l++){
				if(i+j+k+l==n)ans++;
			}
		}
	}
}
cout<<ans<<endl;

return 0;
}

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

int main(){
	int n;
	cin >> n;
	int root[5][50],i,j;
	for(i=0;i<5;i++){
		for (j = 0; j < 50; j++)
			root[i][j] = 0;
	}
	for (i = 0; i<10; i++) {
		root[1][i] = 1;
	}
	for (i = 1; i<5; i++) {
		root[i][0] = 1;
	}
	for(i = 2; i < 5; i++){
		for(j= 1;j<50;j++){
			for (int k = j; k >= 0&&k > j-10;k--) {
				root[i][j] += root[i - 1][k];
			}
		}
	}

	cout << root[4][n] << endl;
}

C++: #include<iostream>

using namespace std;

int main(){
	int n, count=0;
	cin >> n;
	for(int i=0;i<10;++i){
		for(int j=0;j<10;++j){
			for(int k=0;k<10;++k){
				for(int l=0;l<10;++l){
					if(i+j+k+l == n) count++;
				}
			}
		}
	}
	cout << count << endl;
	return 0;
}

C++: #include <iostream>
using namespace std;
int main() {
  int n;
  while (cin >> n) {
    int sum = 0;
    int cnt = 0;
    for (int a = 0; a < 10; ++a) {
    sum += a;
    for (int b = 0; b < 10; ++b) {
    sum += b;
    for (int c = 0; c < 10; ++c) {
    sum += c;
    for (int d = 0; d < 10; ++d) {
    sum += d;
    if (sum == n) cnt++;
    sum -= d;
    }
    sum -= c;
    }
    sum -= b;
    }
    sum -= a;
    }
    cout << cnt << endl;
  }
  return 0;
}

C++: #include <iostream>

using namespace std;

int main(void) {
  int n = 0;
  cin >> n;

  int num = 0;
  for(int a = 0; a < 10; a++) {
    for(int b = 0; b < 10; b++) {
      for(int c = 0; c < 10; c++) {
        for(int d = 0; d < 10; d++) {
          if(a + b + c + d == n) num++;
        }
      }
    }
  }

  cout << num << '\n';

  return 0;
}

C++: #include <iostream>
#include <algorithm>
#include <string>
#include <vector>
#include <stack>
#include <queue>
#include <cstring>
#include <climits>
#include <cmath>
#include <cfloat>

#define FOR(i,b,n) for(int i=b;i<n;i++)
#define CLR(mat) memset(mat, 0, sizeof(mat))
#define INF 1<<25

using namespace std;

int n,sum,out;

int main()
{
	while( cin >> n, !cin.eof())
	{
		out = 0;
		
		FOR(a,0,10)
			FOR(b,0,10)
				FOR(c,0,10)
					FOR(d,0,10)
					{
						if( n == a+b+c+d )
						{
							out++;
						}
					}
		
		
		cout << out << endl;
	}
	
	return 0;
}

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

using namespace std;

main(){
		int l;
		while(cin>>l){
			int o=0;
			for (int a=0; a < 10; a++){
				for (int b=0; b < 10; b++){
					for (int c=0; c < 10; c++){
						for (int d=0; d< 10; d++){
							if(a+b+c+d==l){
								o=o+1;
							}
						}
					}
				}
			}
			printf("%d\n",o);
		}
}

C++: $include<iostream>
using namespace std;
int main(){
int n;
cin>>n;
int counter=0;
for(int a=0;a<10;a++){
for(int b=0;b<10;b++){
for(int c=0;c<10;c++){
if(1<=n-a-b-c && n-a-b-c<=9){
counter++;
}
}
}
}
cout<<counter<<endl;
return 0;
}

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

int main(){
	int t = 0;
	int n;
	int a[100];
	while(cin >> n){
		if(n > 36){
			a[t] = 0;
			continue;
		}
		else if(n > 18){
			n = 36-n;
		}
		a[t] = 1;
		for(int i = n+3; i >=4; i--){
			a[t] = a[t]*i;
		}
		t++;
	}
	for(int i = 0; i < t; i++){
		cout << a[i] << endl;
	}
}

C++: #include <iostream>
#include <algorithm>
#include <cstring>
#include <cmath>
#include <cstdio>
using namespace std;
int n;
int bfs(int sum,int cnt){
//    cout << " " << sum << " " << cnt<< endl;
    if(cnt==4){
        if(n==sum)return 1;
        else return 0;
    }else if(sum>n)return 0;
    int result = 0;
    for(int i=0;i<=9;i++){
        result+=bfs(sum+i,cnt+1);
    }
    return result;
}

int main(){
    while (cin>>n) {
        int result = bfs(0,0);
        cout << result << endl;
    }
    return 0;
}

C++: #include <iostream>

using namespace std;
int main(void){

int input=0;
int output=0;

	cin >>input;

for(int a =0; a<9 ; a++){
	for(int b=0; b<9; b++){
		for(int c=0; c<9;c++){
			for(int d=0; d<9;d++){
			int abcd=a+b+c+d;
				if(abcd==input){
					output++;
				}
			}
		}
	}
}

	cout << output;
}

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

int main(){
    int n,ans;
    
    while(cin>>n){
        ans=0;
        for(int i=0; i<10; i++){
            for(int j=0; j<10; j++){
                for(int k=0; k<10; k++){
                    for(int l=0; l<10; l++){
                        if(n==i+j+k+l) ans++;
                    }
                }
            }
        }
        cout << ans << endl;
    }
    
    return 0;
}

C++: #include <iostream>

using namespace std;

int main()
{
	int n, ans = 0;

	while (cin >> n) {
		for (int i = 0; i < 10; i++) {
			for (int j = 0; j < 10; j++) {
				for (int k = 0; k < 10; k++) {	 
					for (int l = 0; l < 10; l++) {
						if (i + j + k + l == n) {
							ans++;
						}
					}
				}
			}
		}
		cout << ans << endl;
		ans = 0;
	}
}