Problem:
Sum of 4 Integers

Write a program which reads an integer n and identifies the number of combinations of a, b, c and d (0 ≤ a, b, c, d ≤ 9) which meet the following equality:

a + b + c + d = n

For example, for n = 35, we have 4 different combinations of (a, b, c, d): (8, 9, 9, 9), (9, 8, 9, 9), (9, 9, 8, 9), and (9, 9, 9, 8).

Input

The input consists of several datasets. Each dataset consists of n (1 ≤ n ≤ 50) in a line. The number of datasets is less than or equal to 50.

Output

Print the number of combination in a line.

Sample Input

35
1

Output for the Sample Input

4
4

Solution in C# (judge verdict: Accepted)

using System;
using System.IO;
using System.Linq;
using System.Collections.Generic;

public class Program
{

    public void Proc()
    {
        System.Text.StringBuilder ans = new System.Text.StringBuilder();
        while(true) {
            string inpt = Reader.ReadLine();
            if(inpt == null) {
                break;
            }
            int num = int.Parse(inpt);
            ans.AppendLine(GetAns(0, num).ToString());
        }
        Console.Write(ans.ToString());
    
    }

    private long GetAns(int idx, int remain) {
        if(idx >= 4) {
            if(remain == 0) {
                return 1;
            } else {
                return 0;
            }
        }

        long ans = 0;
        for (int i = 0; i <= Math.Min(remain, 9); i++) {
            ans += GetAns(idx + 1, remain - i);
        }
        return ans;
    }


    public class Reader
	{
		private static StringReader sr;
		public static bool IsDebug = false;
		public static string ReadLine()
		{
			if (IsDebug)
			{
				if (sr == null)
				{
					sr = new StringReader(InputText.Trim());
				}
				return sr.ReadLine();
			}
			else
			{
				return Console.ReadLine();
			}
		}
		private static string InputText = @"



35
1


";
	}

	public static void Main(string[] args)
	{
#if DEBUG
		Reader.IsDebug = true;
#endif
		Program prg = new Program();
		prg.Proc();
	}
}