#trick
❇️ Do you print Python variables like this:
❇️ You're working too hard! As of Python 3.8, you can say:
It shows the variable name, =, then the value. Actually, all expressions work:
❇️ Do you print Python variables like this:
>>> print(f'x = {x}')❇️ You're working too hard! As of Python 3.8, you can say:
>>> print(f'{x = }')It shows the variable name, =, then the value. Actually, all expressions work:
>>> print(f'{len("abc") = }')
len("abc") = 3👍9