Il Sat, 17 Oct 2009 23:30:02 -0700 (PDT), StarWing ha scritto: > Sometimes I want to make a simple flags. and i need to check there is > a name in current scope or not (that is, we can visit this name, no > matter where is it). and how to do that in python?
Just use it in a try..except block. try: print myname except NameError: print "myname does not exists" D. -- http://mail.python.org/mailman/listinfo/python-list