Life's better without braces
Gerrit Holl
gerrit.holl at pobox.com
Tue Feb 22 14:33:52 EST 2000
<quote name="Moshe Zadka" date="951206227">
> On Mon, 21 Feb 2000, Gerrit Holl wrote:
>
> > Hello all,
> >
> > I have a problem. In my Python enthuishasm, I ripped off the braces
> > from my keyboard because I thought I didn't need them.
> > Unfortunately, I have a problem now. I can't create dictionairies any
> > more! And because braces aren't the only keys on the brace key,
> > I can't create lists either. The solution for the latter is list(()),
> > but how do I create an empty dictionairy without braces?
>
> >>> import UserDict
> >>> a=UserDict.UserDict().data
> >>> a
> {}
Ah, thanks!
regards,
Gerrit.
--
Comparison Python GUI's: http://www.nl.linux.org/~gerrit/gui.html
Please comment!
More information about the Python-list
mailing list