On Wed, Jul 05, 2006 at 02:51:36PM +0200, ferenc pintye wrote:
> Hi,
> 
> how could i get the name of an array in a string ?

if by this you mean "the name of an identifier refering to [whatever]",
this is a FAQ, and the answer is

1. you don't want to do that
2. your problem is not well behaved (there can be many answers to the
questions)
3. you can use something along the lines of

for name, item in locals().iteritems():
    if item is my_array:
        break
else:
    name = "anonymous object"

-- 
Alexandre Fayolle                              LOGILAB, Paris (France)
Formations Python, Zope, Plone, Debian:  http://www.logilab.fr/formations
Développement logiciel sur mesure:       http://www.logilab.fr/services
Informatique scientifique:               http://www.logilab.fr/science

Attachment: signature.asc
Description: Digital signature

Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Numpy-discussion mailing list
Numpy-discussion@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/numpy-discussion

Reply via email to