import Data.String

main = do
        x <- words <$> getContents
        mapM print (map solve (map read x))

range :: [Int]
range = [0..9]

allList :: [[Int]]
allList = [[a, b, c, d] | a<-range, b<-range, c<-range, d<-range]

solve :: Int -> Int
solve n = length  [y | y<-allList, (foldr (+) 0 y) == n]