Go: package main

import "fmt"

var count int

func main() {
	var inputNum int
	for {
		fmt.Scanf("%d", &inputNum)
		fmt.Printf("%d\n", calcA(inputNum))
		count = 0
	}
}

func calcA(input int) int {
	for i := 0; i <= 9; i++ {
		calcB(input, i)
	}
	return count
}

func calcB(input, a int) {
	for i := 0; i <= 9; i++ {
		calcC(input, a, i)
	}
}

func calcC(input, a, b int) {
	for i := 0; i <= 9; i++ {
		calcD(input, a, b, i)
	}
}

func calcD(input, a, b, c int) {
	for i := 0; i <= 9; i++ {
		if a+b+c+i == input {
			count++
		}
	}
}

Python: cnt = 0
def get_input():
    while True:
        try:
            yield ''.join(input())
        except EOFError:
            break

if __name__ == '__main__':
    array = list(get_input())
    for i in range(len(array)):
        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 == int(array[i]):
                            cnt += 1
        print(cnt)
        cnt = 0

Python: while True:
    try:
        n = int(input())
        Num = 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:
                            Num += 1
        print(Num)
    except EOFError:
        break

Python: while True:
    try:
        n=int(input())
        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==n:ans+=1
        print(ans)
    except:break

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)])