Sep-17-2022, 06:45 PM
Sep-17-2022, 07:24 PM
If you had used Python 3.10 then would have gotten Better error messages
So it i run it on Python 3.10.5,no need to search for an answer as the hint is in error message.
So it i run it on Python 3.10.5,no need to search for an answer as the hint is in error message.
>>> print(1,012,000) File "<interactive input>", line 1 print(1,012,000) ^ SyntaxError: leading zeros in decimal integer literals are not permitted; use an 0o prefix for octal integers >>> print(1,0o12,000) 1 10 0 >>> >>> print(1,000,000) 1 0 0
Sep-17-2022, 10:44 PM
Interesting that 000 does not have leading zeros.
Sep-18-2022, 11:51 AM
Wild guess here, but I bet you wanted it to print 1,012,000. As in a million twelve thousand. In that case, you need to ditch the commas.