i = 10
last_number = 1
def print_numbers(last_number):
while i > 1:
print(i)
i = i - 1
print('finished!')
>>> def print_numbers(last_number): ... i = 10 ... while i >= last_number: ... print(i) ... i = i - 1 ... >>> print_numbers(1) 10 9 8 7 6 5 4 3 2 1 >>> print('finished!') finished! >>>