This is a quirk of shell.appspot.com. I've not dug into the code, but perhaps it is something to do with how the session context updated and stored.
Try this: >>> x = [1, 2, 3]; x[2] = '345' >>> print x That will give you the result you expect, and will match the behavior of a local Python interactive prompt. Robert On Fri, Mar 11, 2011 at 05:30, nik <[email protected]> wrote: > Hi, i am new in python programming and i tried to use the online > Interactive server-side Python shell (http://shell.appspot.com) to > test the list data type and while it supposed to be changeable, this > is not the way is treated: > >>>> x=[2,5,6] >>>> x[2]='111' >>>> print x > [2, 5, 6] > > x[2] wasn't supposed to change? if so then is this a bug of the online > shell or it is the way that any deployed application in app engine is > treated? > > -- > You received this message because you are subscribed to the Google Groups > "Google App Engine" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/google-appengine?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
