> > e.g. can you predict the result of the following operations without trying
> > it?
> >
> > a = [1, 2, 3, 4]
> > a[1:3] = [7, 8]
> > print a
>
> [1, 7, 8, 4] Whew!
> (I really wasn't positive that it shouldn't be [1, [7, 8], 4] !)
good job dick! of course, you *know* i'm going to ask this...
how *do* you get it to be [1, [7, 8], 4] given the original 'a'? :-)
cheers,
-- wesley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"Core Python Programming", Prentice Hall, (c)2007,2001
http://corepython.com
wesley.j.chun :: wescpy-at-gmail.com
python training and technical consulting
cyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com
_______________________________________________
Tutor maillist - [email protected]
http://mail.python.org/mailman/listinfo/tutor