@[email protected] to Programmer [email protected] • 1 year agoThe Perfect Solutionprogramming.devimagemessage-square71fedilinkarrow-up1657arrow-down18
arrow-up1649arrow-down1imageThe Perfect Solutionprogramming.dev@[email protected] to Programmer [email protected] • 1 year agomessage-square71fedilink
minus-square@renzevlink1•1 year agoPython is so great (half-sarcasm) that a trailing comma on its own constitutes a tuple (immutable list): mytuple = 4, assert len(mytuple) == 1 assert mytuple[0] == 4
Python is so great (half-sarcasm) that a trailing comma on its own constitutes a tuple (immutable list):
mytuple = 4, assert len(mytuple) == 1 assert mytuple[0] == 4