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 <iostream>

using namespace std;

int main(){

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

	while(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){
						count = count +1;
					}
				}
			}
		}
	}

	cout << count << endl;
}
}

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

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

C++: //0008 Sum of 4 Integers
//nツつェツ与ツつヲツづァツづェツつスツづつォツ、a+b+c+d=nツづづ按づゥツ組ツづ個古つ青板づーツ出ツ療債つケツづヲ
//ツづ按つィツ、n<=50ツ、0<=a,b,c,d<=9ツづつキツづゥ
//ツ禿シツ療債づ個終ツづュツづィツづ孔OFツづ与ツつヲツづァツづェツづゥ

#include<iostream>
#include<numeric>
using namespace std;

int main(void)
{
	const int N = 4;
	int a[N];
	int n;
	while( cin >> n)
	{
		int count = 0;
		for(int i = 0; i < 10*10*10*10; i++)
		{
			a[0] = i/10/10/10;
			a[1] = i/10/10%10;
			a[2] = i/10%10;
			a[3] = i%10;
			if(accumulate(a, a+N, 0) == n)
				count++;
		}
		cout << count << endl;
	}
}

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

int main(){
//old
		/* 2014 ??????1
		int a[2],ans;
		cin >> a[0] >> a[1];
		ans = a[0] * a[1];
		cout << ans << endl;
		*/
		/* 2014 ??????2
		int a[6],ans = 0;
		cin >> a[0] >> a[1] >> a[2] >> a[3] >> a[4] >> a[5];
		if(a[0] + a[1] * 5 + a[2] * 10 + a[3] * 50 + a[4] * 100 + a[5] * 500 >= 1000) ans = 1;
		cout << ans << endl;
		*/
		/* 2014 ??????3
		int a,i = 0;
		cin >> a;
		int b[a],c[a],ans[a];
		while(a > i){
			cin >> b[i] >> c[i];
			ans[i] =  b[i] % c[i];
			if(ans[i] == 0) ans[i] = c[i];
			i++;
		}
		i = 0;
		while(a > i){
		cout << ans[i] << endl;
		i++;
		}
		*/
		/* 2014 ??????4
		int a[2],i = 1;
		cin >> a[0];
		int n[a[0]],m[a[0]];
		while (a[0] >= i){
			cin >> n[i] >> m[i];
			i++;
		}
		i = 1;
		cin >> a[1];
		int o[a[1]],p[a[1]];
		while (a[1] >= i){
			cin >> o[i] >> p[i];
			i++;
		}
		i = 1;
		int ii,c,aa;
		aa = a[0] + a[1];
		int ans[aa][2],hh[aa],mm[aa],chk,count = 1;
		while(aa >= i){
			ii = 1;
			chk = 1;
			if(a[0] >= i){
				while(i - 1 >= ii){
					if(n[i] == hh[ii] and m[i] == mm[ii]){
						chk = 0;
					}
					ii++;
				}
				if(chk == 1){ 
					hh[count] = n[i];
					mm[count] = m[i];
					count++;
				}
			}else{
				while(i - 1 >= ii){
					if(o[i - a[0]] == hh[ii] and p[i - a[0]] == mm[ii]){
						chk = 0;
					}
					ii++;
				}
				if(chk == 1){ 
					hh[count] = o[i - a[0]];
					mm[count] = p[i - a[0]];
					count++;
				}		

			}
			i++;
		}
		aa = count - 1;
		i = 1;
		while(aa >= i){
			ii = 1;
			c = 1;
				while(aa >= ii){
						if(hh[i] > hh[ii] or hh[i] == hh[ii] and mm[i] > mm[ii] and i != ii){
							c++;
						}
				ii++;
				}
			ans[c][0] = hh[i];
			ans[c][1] = mm[i];
		 i++;
		}
		i = 1;
		while(aa >= i){
			if(aa == i){
				if(ans[i][1] < 10){
					cout << ans[i][0] << ":" << "0" << ans[i][1] << endl;;
				}else{
					cout << ans[i][0] << ":" << ans[i][1] << endl;;
				}

			}else{
				if(ans[i][1] < 10){
					cout << ans[i][0] << ":" << "0" << ans[i][1] << " ";
				}else{
					cout << ans[i][0] << ":" << ans[i][1] << " ";
				}
			}
			i++;
		}
		//????????°???
		int n,i,ans = 100000,a,risi[2];
		cin >> n;
		for(i = 1;n >= i;i++){
			risi[0] =  ans * 0.05;
			risi[1] = risi[0];
			while(risi[1] >= 1000){risi[1] = risi[1] - 1000;}
				if(risi[1] > 0){risi[0] = risi[0] - risi[1] + 1000;}
			ans = ans + risi[0];
		}
		cout << ans << endl;
		*/
//old
	int in,i[4],ans = 0,s[4] = {0,0,0,0};
	cin >> in;
	for(i[0] = 0;9 >= i[0];i[0]++){
		//if(0 > in - i[0]) break;
		//cout << "[1]" <<  i[0] << endl;				
		for(i[1] = 0;9 >= i[1];i[1]++){
			//if(0 > in - ( i[0] + i[1] ) ) break;
			//cout << "[2]" << i[1] << endl;
			for(i[2] = 0;9 >= i[2];i[2]++){
				//if(0 > in - ( i[0] + i[1] + i[2] ) ) break;
				//cout << "[3]" << i[2] << endl;
				for(i[3] = 0;9 >= i[3];i[3]++){
					//if(0 > in - ( i[0] + i[1] + i[2] + i[3] ) ) break;
					//cout << "[4]" << i[3] << endl;
					//cout << "[1] " << i[0] << "  [2] " << i[1] << "  [3] " << i[2] << "  [4] " << i[3] << endl; 
					if(i[0] + i[1] + i[2] + i[3] == in){
					//cout << "[1] " << i[0] << "  [2] " << i[1] << "  [3] " << i[2] << "  [4] " << i[3] << endl; 
					ans++;
					}
				}	
			}
		}
	}
	cout << ans << endl;
	/*int in;
	cin >> in;
	int a[in];
	for(int i = 1;in >= i;i++){
		cout << "[IN] [" << i << "] ";
		cin >> a[i];
	}
	for(int i = 1;in >= i;i++){cout << "[OUT] ["<< i << "] " <<  a[i] << endl;}*/
}

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

int n;

int main()
{
	while (cin >> n) {
		int m = 0;

		if (n < 37) {
			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)
								m++;
		}

		cout << m << endl;
	}

	return 0;
}

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

int main(void)
{
	int num, total = 0;

	while (cin >> num) {
		int C[11] = {0};
		C[10] = 4;
		for (int i = 9; i > 0 && num; i--) {
			while (num-i >= 0) {
				C[10]--;
				C[i]++;
				num -= i;
			}
		}
		total = 0;
		if (num == 0) {
			total = 24;
			for (int i = 0; i < 11; i++) {
				while (C[i] > 0) {
					total /= C[i];
					C[i]--;
				}
			}
		}
		cout << total << endl;
	}
	
	return 0;
}

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

#define REP(i,n) for (int (i) = 0; (i) <= (n); ++(i))
int main() {
    int n;
    int ret = 0;
    while(cin>>n){
        ret =0 ;
        REP(a, 9)REP(b, 9)REP(c, 9)REP(d, 9)if(a+b+c+d == n)ret++;
        cout<<ret<<endl;
    }
    return 0;
}

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

int main(void){
	int n,a,b,c,d,count;
	while(scanf("%d",&n)!=EOF){
		count=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){
							count++;
						}
					}
				}
			}
		}
		printf("%d\n",count);
	}
	}

C++: #include <fstream>
#include <iostream>
#include <cmath>
#include <vector>
#include <queue>
#include <utility>
#include <algorithm>
using namespace std;

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

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

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

C++: #include<iostream>
using namespace std;
int main(){
	int a,b=0;
	while(cin>>a){
		for(int a1=1;a1<10;a1++){
			for(int a2=1;a2<10;a2++){
				for(int a3=1;a3<10;a3++){
					for(int a4=1;a4<10;a4++){
						if(a1+a2+a3+a4==a){
							b++;
						}
					}
				}
			}
		}
		cout<<b<<endl;
	}
	return 0;
}