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 <stdio.h>

int cnt, n, a, b, c, d;

int main(void)
{
  while(scanf("%d",&n) == 1)
  {
    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++;
    printf("%d\n",cnt);
  }
  return 0;
}

C++: #include<iostream>

int main(){
	int a,b,c,d,i,n;
	
	i=0;
	std::cin>>n;
	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){
						i++;
						}
					}
				}
			}
		}
	std::cout<<i<<std::endl;
	
	return 0;
}

C++: #include <iostream>
using namespace std;
int main() {
  int n, count = 0;
  cin >> n;
  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++)
          if (a+b+c+d == n)
            count++;
  cout << count << endl;
}

C++: #include <stdio.h>
#include <string.h>

int dp[51][5];

void init() {
  memset(dp, 0, sizeof(dp));
  dp[0][0] = 1;
  for (int i = 1; i <= 50; ++i) {
    for (int j = 1; j <= 4; ++j) {
      for (int t = 0; t < 10 && t <= i; ++t) {
        dp[i][j] += dp[i-t][j-1];
      }
    }
  }
}

int main() {
  //freopen("SumOf4Integers.in", "r", stdin);
  int n;
  init();
  while (scanf("%d", &n) == 1) {
    int result = dp[n][4];
    printf("%d\n", result);
  }
  return 0;
}

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

int main(void) {
	int  n, c = 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)
					  c++;
				}
			}
		}
	}
	cout << c << endl;
	return 0;
}

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

int main(){
  int n,i,S;
  while(1){
    i=0;
    cin>>n;
    for(S=1;S<=9999;S++){
      if((S/1000)+((S-S/1000*1000)/100)+((S-S/100*100)/10)+(S-S/10*10)==n)
	i=i+1;
    }
    cout<<i<<endl;
  }
  return 0;
}

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

int main(){

  int n;

  while(cin >> n){

    int i,j,k,l;
    int ans = 0;

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

  return 0;
}

C++: #include "stdio.h"

int main()
{
	int n, m, l;

	scanf("%d", &n);

	m = n;
	l = 0;

	for (int a = 0; a < 10; a++){
		if (m < a) break;
		else m -= a;
		for (int b = 0; b < 10; b++){
			if (m < b) break;
			else m -= b;
			for (int c = 0; c < 10; c++){
				if (m < c) break;
				else m -= c;
				for (int d = 0; d < 10; d++){
					if (m < d) break;
					else if(m == d) l++;
				}
				m += c;
			}
			m += b;
		}
		m += a;
	}

	printf("%d\n", l);
}

C++: #include <iostream>

using namespace std;

#define rep(i,n) for(int i=0;i<n;i++)

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

C++: #include <string>
#include <algorithm>
#include <cfloat>
#include <climits>
#include <cmath>
#include <complex>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <functional>
#include <iostream>
#include <map>
#include <memory>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <utility>
#include <vector>
#include <iomanip>


using namespace std;

typedef unsigned long long ull;
int main(void) {
	int n, res = 0;
	cin >> n;
	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++){
		if(a + b + c + d == n)res++;
	}	
	}	
	}	
	}
	cout << res << endl;
}

C++: //52
#include<iostream>
 
using namespace std;
 
int main(){
  for(int n;cin>>n;){
    int ans=0;
    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++){
        ans+=a+b+c+d==n;
      }
    }
      }
    }
    cout<<ans<<endl;
  }
  return 0;
}

C++: #include <iostream>
#include <cstdio>
using namespace std;
#define REP0(i,n) for(int i=0;i<n;++i)
#define REP1(i,n) for(int i=1;i<=n;++i)
#define ALL(c) (c).begin(),(c).end()
int main(){
	int n;
	while(scanf("%d",&n)!=EOF){
		int ans=0;
		REP0(a,10) REP0(b,10) REP0(c,10) REP0(d,10) if(a+b+c+d==n) ans++;
		printf("%d\n",ans);
	}
	return 0;
}

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

int main(){
  
  vector<int> count_array;
  int count;
  int in_num;
  int a,b,c,d,i=0;
  while(cin>>in_num){
    count=0;
    if(in_num>36)break;
    else{
      for(a=0;a<10;a++){
	for(b=0;b<10;b++){
	  for(c=0;c<10;c++){
	    for(d=0;d<10;d++){
	      if((a+b+c+d)==in_num){
		count++;
	      }
	    }
	  }
	}
      }
      count_array.push_back(count);
      ++i;
    }
  }
  for(int j=1;j<i;j++){
    cout<<count_array[j]<<endl;
  } 
}

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

int main(){
	int n;
	while(cin >> n){
		int count = 0;
		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){
							count++;
						}
					}
				}
			}
		}
		cout << count << endl;
	}
    return 0;
}

C++: #include<iostream>
#include<iomanip>
#include<cstdio>
#include<vector>
#include<algorithm>
#include<cmath>
#include<queue>
#include<stack>
#include<functional>
#include<string>
#include<cstring>
#include <sstream>
using namespace std;
int main(void){
    int n,ans,i,j,k,l;
    cin >> n;
    ans = 0;
    for(i = 0; i <= 9; i++){
        for(j = 0; j <= 9; j++){
            for(k = 0; k <= 9; k++){
                for(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;
	while (cin>>n)
	{
		int combo = 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)
					++combo;
			}
			}
			}
		}
		cout<<combo<<endl;
	}
	return 0;
	cin.get();
	getch();
}

C++: #include<iostream>

using namespace std;

int main(){
	int n;
	int 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++){
						ans += (i + j + k + l == n);
					}
				}
			}
		}
		cout << ans << endl;
	}
}

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

#define rep(i, j) for(int i = 0; i < j; i++)
// rep2
#define rep2(i, j) for(int i = 1; i <= j; i++)
#define all(i) i.begin(), i.end()
#define ll long long

using namespace std;

string Num2Str(int num)
{
	stringstream ss;
	ss << num;
	return ss.str();
}

int main()
{
	cin.tie(0);
	ios::sync_with_stdio(false);

	// code
	int n, cnt = 0;
	cin >> n;
	rep2(a, 9) {
		rep2(b, 9) {
			rep2(c, 9) {
				rep2(d, 9) {
					if (n == (a + b + c + d)) cnt++;
				}
			}
		}
	}
	cout << cnt << endl;

	return 0;
}