there was extra bracket in both cases on line 3
for n in (2, 12, 0, 1): try: print(f'72 divided by {n} is {72 / n}.') except ZeroDivisionError: print ('72 divided by 0 produces an Error: Invalid argument.')
def divide72(divisor): try: print(f'72 divided by {n} is {72 / divisor}.') except ZeroDivisionError: print ('72 divided by 0 produces an Error: Invalid argument.') for n in (2, 12, 0, 1): divide72(n)sorry, it was my mistake
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs