On 4/22/2012 12:39 PM, mambokn...@gmail.com wrote:


Question:
How can I access to the global 'a' in file_2 without resorting to the whole 
name 'file_1.a' ?

Actually, it's better to use the fully qualified name "file_1.a". Using "import *" brings in everything in the other module, which often
results in a name clash.

    Just do

import file_1

and, if desired

localnamefora = file_1.a



                                        John Nagle
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to