Hi, i have been trying to learn python from a book learn python the hard way and i am trying to learn how to use code in two different files simultaneously. I can't get it to work though, this is what i'm doing.
File 1:
File 2:
These are obviously just tests but the error says name 'a' is not defined? Please help
File 1:
Code:
import test2 a.test1()
File 2:
Code:
class test:
def test1(self):
print "Test"
a = test()
Comment