I'm working on Learn python the hard way and am not a very experienced programmer and I have searched on Stackoverflow and other programming websites but I have not found the answer to my question. Well anyway my question is how do you import files into another file in python what I have seen is that many people have answered this by saying that you should just put import filename but when I do this I get the error Traceback (most recent call last):
File "source.py", line 1, in <module>
import one
ImportError: No module named filename so how do I import a file without getting this error. if anybody would like to know where to go to see why I'm asking question go to http://learnpythonthehardway.org/book/ex45.html. I'm also using a chromebook so I have an app named source lair instead of the traditional python software, so if anybody has a chromebook or chromeos computer please give me suggestions as to if this is a good app and if there's a better app. ps: you can download the app from the chrome store on any operating system.
print "thanks"
filename.pyin the same directory asscript.py?filename, if your file is saved as something other than "filename" you need to use the actual filename. For example, if your file is called "game.py" you should useimport game