[Python-ideas] dictionary unpacking

Mathias Panzenböck grosser.meister.morti at gmx.net
Mon Mar 31 16:17:11 CEST 2008


Maybe dictionary unpacking would be a nice thing?

 >>> d = {'foo': 42, 'egg': 23}
 >>> {'foo': bar, 'egg': spam} = d
 >>> print bar, spam
42 23


What do you think? Bad idea? Good idea?

	-panzi



More information about the Python-ideas mailing list