← back to unit
Easy
# basics io
Changing the Separator
When you print multiple things with commas, Python puts a space between them by default. You can change that with sep=:
print(1, 2, 3, sep="-")
This prints: 1-2-3
Your turn: print 2024, 1, and 1 (in that order) using sep="-" so it reads like a date: 2024-1-1
💡 need a hint?
pyb-io-print-sep.py
loading...