MRAB wrote: > You could create a dict with the string as the key and the object as the > value.
Thanks. But it implies an additional data structure: a dictionnary. I don't know what is the best: * using an additional dict and maintaining it * or using the "di" module proposed by CTO If "di" is reliable, it seems a good solution for my initial constraint which is the impossibility to store anything but strings in my data structure. -- python -c "print ''.join([chr(154 - ord(c)) for c in '*9(9&(18%.\ 9&1+,\'Z4(55l4('])" "When a distinguished but elderly scientist states that something is possible, he is almost certainly right. When he states that something is impossible, he is very probably wrong." (first law of AC Clarke) -- http://mail.python.org/mailman/listinfo/python-list