def for_test(x, y):
    for y in range(x):
        return combination(x, y)

def pascals_triangle(rows):
    result = []
for count in range(rows):
    row = []
for element in range(count + 1):
    row.append(combination(count, element))
result.append(row)
return result
for row in pascals_triangle(3):
    pass
Pascal's Triangle for Python