Boris Ozegovic wrote: > 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
Are you sure the above is what you really used for your test? Because your output features a single 100, which the above lacks a print-statement for. Diez -- http://mail.python.org/mailman/listinfo/python-list