ar = (0..9)
while str = gets do
    n = str.chomp.to_i
    count = 0
    ar.each do |a|
        num = a
        break if num > n
        if num == n
            count += 1
            break
        end
        ar.each do |b|
            num += b
            break if num > n
            if num == n
                count += 1
                break
            end
            ar.each do |c|
                num += c
                break if num > n
                if num == n
                    count += 1
                    break
                end
                ar.each do |d|
                    num += d
                    break if num > n
                    if num == n
                        count += 1
                        break
                    end
                end
            end
        end
    end
    puts count
end