On Mon, Mar 14, 2022 at 9:49 AM Chris Angelico <[email protected]> wrote:
> On Mon, 14 Mar 2022 at 23:35, <[email protected]> wrote: > > > > Currently: > > l = [] # new empty list > > t = () # new empty tuple > > s = set() # new empty set (no clean and consistent way of initializing > regarding the others) <<< > > d = {} # new empty dictionary > > > > Possible solution: > > s = {} # new empty set > > d = {:} # new empty dictionary (the ":" is a reference to key-value > pairs) > > Nope, that would break tons of existing code. Not gonna happen. > Of couse not. (And I mean it). - but what about keeping what exists and adding {,} for an empty set? (it is not that unlike the one-element tuple, which already exists) > > ChrisA > _______________________________________________ > Python-ideas mailing list -- [email protected] > To unsubscribe send an email to [email protected] > https://mail.python.org/mailman3/lists/python-ideas.python.org/ > Message archived at > https://mail.python.org/archives/list/[email protected]/message/PCPZPHCNXOW6ADAOUXY25MTRDNXI4EQI/ > Code of Conduct: http://python.org/psf/codeofconduct/ >
_______________________________________________ Python-ideas mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/[email protected]/message/LLS7SPT4XHLDCSHHKK3ZKXTHKA4R2LMV/ Code of Conduct: http://python.org/psf/codeofconduct/
