Re: hash of hashes

2006-07-11 Thread sfo
Thanks to all for the feedback. it worked. --RR Tim Chase wrote: > > how do i create a hash of hash similar to perl using dict in python > > $x{$y}{z}=$z > > Pretty much the same as in perl, only minus half the crazy abuses > of the ASCII character-set. > > Okay...well, not quite half the abuses

Re: hash of hashes

2006-07-11 Thread Tim Chase
> how do i create a hash of hash similar to perl using dict in python > $x{$y}{z}=$z Pretty much the same as in perl, only minus half the crazy abuses of the ASCII character-set. Okay...well, not quite half the abuses in this case... >>> x = {} >>> y = 42 >>> z = 'foonting turlingdromes' >>

Re: hash of hashes

2006-07-11 Thread Marc 'BlackJack' Rintsch
In <[EMAIL PROTECTED]>, sfo wrote: > how do i create a hash of hash similar to perl using dict in python > $x{$y}{z}=$z Just put dictionaries as values into a dictionary. Ciao, Marc 'BlackJack' Rintsch -- http://mail.python.org/mailman/listinfo/python-list

Re: hash of hashes

2006-07-11 Thread Ant
sfo wrote: > how do i create a hash of hash similar to perl using dict in python > $x{$y}{z}=$z Haven't done any Perl in a long while (thankfully ;-) ) so I'm not quite sure on your syntax there, but here's how to do it in Python: >>> x = {'y': {'z': 'My value'}} >>> x['y']['z'] 'My value' Much

hash of hashes

2006-07-11 Thread sfo
how do i create a hash of hash similar to perl using dict in python $x{$y}{z}=$z thanks. --RR -- http://mail.python.org/mailman/listinfo/python-list