An `non decreasing` number is one containing no two consecutive digits (left to right), whose the first is higer than the second. For example, 1235 is an non decreasing number, 1229 is too, but 123429 isn't.
Write a function that finds the number of non decreasing numbers up to `10**N` (exclusive) where N is the input of your function. For example, if `N=3`, you have to count all non decreasing numbers from 0 to 999.
 You'll definitely need something smarter than brute force for large values of N!
from math import factorial
from functools import reduce
import operator
def increasing_numbers(digits):
    if digits == 0:
        return 1
    if digits == 1:
        return 10
    consec_pro = reduce(operator.mul, (i for i in range(10, 10 + digits)))
    return consec_pro / factorial(digits)    
from math import factorial
from functools import reduce
import operator
def increasing_numbers(digits):
    if digits == 0:
        return 1
    if digits == 1:
        return 10
    consec_pro = reduce(operator.mul, (i for i in range(10, 10 + digits)))
    return consec_pro / factorial(digits)    