module Main where
 
import Control.Applicative
import Control.Monad
import Data.List
import Data.Array
import Text.Printf
import Data.Fixed
import Debug.Trace

solve total = [(x,y,z,w) | x <- [0..9], y <- [0..9], z <- [0..9], w <- [0..9], x + y + z + w == total ]

main :: IO ()
main = do
    ns <- fmap (fmap (read :: String -> Int) . words) . lines <$> getContents
    -- ns <- fmap (fmap (read :: String -> Int) . words) . lines <$> (return "35\n1\n")
    forM_ [0..length ns - 1] $ \i -> do
      putStrLn $ show $ length $ solve (ns!!i!!0)