from functools import reduce total = reduce(lambda x, y: x * y, range(40, 20, -1), 1) total = reduce(lambda x, y: x // y, range(1, 21), total) print(total)