On Thu, Apr 11, 2013 at 3:43 PM, Thomas Goebel < thomas.goe...@ohm-hochschule.de> wrote:
> ... > > I get a syntax error, as I exepected (Python 2.6.4 (r264:75708, Oct 26 > > 2009, 08:23:19)). > > Sorry Franz, > > as you are using python 2.6 you have to use > > d1 = dict(('list_' + str(i), []) for i in range(3)) > d2 = dict(('list_' + str(i), [m for m in range(3)]) for i in range(3)) > > like stated here: > > http://stackoverflow.com/questions/1747817/python-create-a-dictionary-with-list-comprehension > -- > Thank you, Thomas, for your last posting and your help, that makes everything clear for me now! All best, Franz
-- http://mail.python.org/mailman/listinfo/python-list