On Thu, 3 Nov 2005, Chris McCoy wrote:

> Thank you!  I've been banging my head against the wall!
>
> Chris M.

>> gridSystemId = [[None]*columns]*rows
>
> You've made gridSystemID a list of `rows` references to the SAME "inner"
> list, so the behavior you observe is the only possible one.
>
> If you want copies instead, ASK for copies...:
>
> gridSystemId = [ [None]*columns for x in xrange(rows) ]


Interesting, could not pychecker recognize such situations in Python
code and give warnings?


Sincerely yours, Roman Suzi
-- 
[EMAIL PROTECTED] =\= My AI powered by GNU/Linux RedHat 7.3
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to