I have a file containing python\'s object as string, then i open it and doing things like i showing:
>>> file = open(\'gods.txt\') >>> file
You can store the lines list in a variable and then access it whenever you want:
file = open('gods.txt') # store the lines list in a variable lines = file.readlines() # then you can iterate the list whenever you want for line in lines: print line