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
}

Python: def count(num):    
    l1=[]
    for a in range (10):
        for b in range(10):
            for c in range (10):
                for d in range (10):
                    l1.append([a,b,c,d])
    l1=list(filter(lambda x: sum(x)==num,l1))
    return(len(l1))

while True:
    try:
        print(count(int(input())))
    except:
        break

Python: import itertools
while True:
	try: n=int(input())
	except EOEError: break
	ans=0
	for (i,j,k) in itertools.product(range(10),range(10),range(10)):
		ans+=(0<=n-(i+j+k)<=9)
	print(ans)

Python: a = [0 for i in range(51)]
for i in range(10):
  for j in range(10):
    for k in range(10):
      for l in range(10):
        a[i + j + k + l] += 1
while True:
  try:
    n = int(input())
    print(a[n])
    
  except EOFError:
    break

Python: while True:
	try:
		cnt=0
		i=int(input())
		for a in range(10):
			for b in range(10):
				for c in range(10):
					for d in range(10):
						if a+b+c+d==i:
							cnt+=1
		print(cnt)
	except:
		break

Python: while True:
    try:
        n=int(input())
        ans=0
        for a in range(0,10):
            for b in range(0,10):
                for c in range(0,10):
                    if 0<=(n-(a+b+c))<=9:
                        ans+=1
        print(ans)
    except:
        break

Python: while True:
    try:
        n = int(input())
        cnt = 0
        for i in range(10):
            for j in range(10):
                for k in range(10):
                    for l in range(10):
                        if i+j+k+l == n:
                            cnt += 1
        print(cnt)
    except:
        break

Python: #!/usr/bin/env python
# -*- conding: utf-8 -*-
import sys

for line in sys.stdin.readlines():
    n = int(line.strip())
    if n > 36:
        print(0)
        continue
    elif n == 36:
        print(1)
        continue
    cnt = 0
    for a in range(10):
        for b in range(10):
            for c in range(10):
                d = n - (a + b + c)
                if 0 <= d and d <= 9:
                    cnt += 1
    print(cnt)

Python: import sys
d = [sum((10 - abs(9 - i)) * (10 - abs(9 + i - j)) for i in range(j + 1)) for j in range(19)[:: -1]] + [0] * 14
[print(d[abs(18 - int(e))]) for e in sys.stdin]

Python: import sys
import math as mas

n=int(input())
out=0
for i in range(10):
	for j in range(10):
		for k in range(10):
			for l in range(10):
				if(i+j+k+l==n):out+=1
print(out)

#for i in sys.stdin:
#	a,b=map(int,i.split())
#	print(gcd(a,b),lcm(a,b))

Python: while True:
    try:
        inVal = int(input())
        count = 0;
        for a in range(10):
            for b in range(10):
                for c in range(10):
                    for d in range(10):
                        if a + b + c + d == inVal:
                            count = count + 1
        print(count)
    except EOFError:
        break

Python: n = int(input())
cnt = 0
for i in range(10):
    for j in range(10):
        for k in range(10):
            for l in range(10):
                if i+j+k+l == n:
                    cnt += 1
print(cnt)

Python: n=int(input())
count=0
for a in range(0,10):
    for b in range(0,10):
        for c in range(0,10):
            if 50-a-b-c>=0 and 50-a-b-c<10:
                count+=1
print(count)

Python: while True:
    try:
        n = int(input())
        counter = 0

        for o in range(10):
            for p in range(10):
                for q in range(10):
                    for r in range(10):
                        if (o + p + q + r) == n:
                            counter = counter + 1

        print(counter)
    except:
        break

Python: while True:
    try:
        n = int(input())
        c = 0
        for i in range(10):
            for j in range(10):
                for k in range(10):
                    for l in range(10):
                        if i+j+k+l == n : c+=1
        print(c)
    except:
        break

Python: import sys
t = [0 for i in range(10000)]
c = 0
for i in range(10):
    for j in range(10):
        for k in range(10):
            for l in range(10):
                t[c] = i + j + k + l
                c += 1
for line in sys.stdin:
    print(t.count(int(line)))

Python: import sys
r = range(10)
for l in sys.stdin: print(len([[a,b,c,d]for a in r for b in r for c in r for d in r if a+b+c+d==int(l)]))

Python: def wa(n):
    count=0
    for i in range(10):
        for j in range(10):
            for k in range(10):
                for l in range(10):
                    if n==i+j+k+l:
                        count +=1
                    elif n<i+j+k+l:
                        break
    return count
while True:
    try:
        n=int(input())
        print(wa(n))
    except:break

Python: ans = []
for line in sys.stdin:
    answ = 0
    n = int(line)
    for a in range(10):
        for b in range(10):
            for c in range(10):
                if 0 <= n-a-b-c <= 9:
                    answ += 1
    ans.append(answ)
for i in ans:
    print(i)

Python: while 1:
    try:
        ct=0
        n=input()
        for a in xrange(10):
            for b in xrange(10):
                for c in xrange(10):
                    if 0<=n-(a+b+c)<=9:
                        ct+=1
        print(ct)
    except:
        break

Python: from itertools import product

while True:
    try:
        total = int(input())
        c = 0
        for t in product(range(10),repeat=4):
            if total == sum(t):
                c += 1
        print(c)

    except:
        break

Python: num = int(input())
count = 0
for a in range(10):
	for b in range(10):
		for c in range(10):
			for d in range(10):
				if a+b+c+d==num:
					count+=1
print(int(count))

Python: # -*- coding:utf-8 -*-
import sys

x = [0]*51
for a in range(10):
    for b in range(10):
        for c in range(10):
            for d in range(10):
                x[a+b+c+d] += 1

array = []
for i in sys.stdin:
    array.append(i)

for k in range(len(array)):
    n = array[k]
    print(x[int(n)])

Python: import sys
 
def ans(num):
    ans = 0
 
    for a in range(10):
        for b in range(10):
            for c in range(10):
                for d in range(10):
                    if a+b+c+d == num:
                        ans += 1
 
    return ans
 
 
def main():
    a = []
 
    for line in sys.stdin:
        a.append(int(line))
 
    for line in a:
        print(ans(line))
 
if __name__ == "__main__":
    main()

Python: import sys

ans=[]    
def sumint(lp,ttl):
    if (ttl > lp*9) | (ttl < 0):
        return 0
    elif lp == 1:
        return 1
    else:
        a = 0
        for n in range(0,10) :
            a += sumint(lp - 1,ttl - n)
        return a

for i in sys.stdin:
    ans.append(sumint(4,int(i)))
print('\n'.join(map(str,ans)))

Python: while 1:
    try:
        n = int(input())
    except:break
    ans = 0
    for i in range(0,10):
        for j in range(0,10):
            for k in range(0,10):
                for l in range(0,10):
                    if i + j + k + l == n:
                        ans += 1

    print(ans)

Python: ans = [0 for i in range(51)]
for i in range(10):
    for j in range(10):
        for k in range(10):
            for l in range(10):
                ans[i+j+k+l] += 1
#for i in range(50+1):
#   print(i, ans[i])
     
while True:
    try:
        print(ans[int(input())])
    except EOFError:
        break