import Control.Monad
import Control.Applicative
main = do
  nums <- map read <$> lines <$> getContents
  forM_ nums $ \i -> do
    print $ length $ [() | a<-[0..9], b<-[0..9], c<-[0..9], d<-[0..9], a + b + c + d == i]
