Can somebody explaint this to me:

I have module a.py
A = 100
import b
print "A printing"
print "B is %s" % b.B

and module b.py
B = 2000
import a
print "B printing"
print "A is %s" % a.A

I thought that output would be:
B printing
A is 100
A printing
B is 2000

Because import b would execute b.py, and in b.py line "import a" would be
ignored, but my output is:

>>> import a
100
A printing
B is 100

??

:)

-- 
http://www.nacional.hr/articles/view/23894/23
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to