Please help about an instance var
JStoneGT at aol.com
JStoneGT at aol.com
Tue Feb 13 21:54:29 EST 2007
>>> from UserDict import UserDict
>>> d = {1:2,3:4,5:6}
>>> d1 = UserDict(d)
>>> d1
{1: 2, 3: 4, 5: 6}
>>> d1.data
{1: 2, 3: 4, 5: 6}
Here why both d1 and d1.data have the same values?As shown below,they're
different types.
>>> type(d1)
<type 'instance'>
>>> type(d1.data)
<type 'dict'>
Please help.Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20070213/6fe85971/attachment.html>
More information about the Python-list
mailing list