Little Q: how to print a variable's name, not its value?
Christos TZOTZIOY Georgiou
tzot at sil-tec.gr
Tue Mar 29 06:12:55 EST 2005
On 28 Mar 2005 22:06:44 -0800, rumours say that
"stewart.midwinter at gmail.com" <stewart.midwinter at gmail.com> might have
written:
<snip complete article-- subject is enough>
Read about locals() and globals() in the Python documentation. These
provide the information you request (ie what names are bound to what
objects).
--
TZOTZIOY, I speak England very best.
"Be strict when sending and tolerant when receiving." (from RFC1958)
I really should keep that in mind when talking with people, actually...
More information about the Python-list
mailing list