Hi Danny, Thanks for your suggestion.
The ideal of output of this program is to show if there is any new number added to the new file. In other words, the file content of file1 [0001.hk, 0002.hk, 0003.hk, 0004.hk] is comparing with the file content of file2 [0001.hk, 0002.hk, 0003.hk, 0005.hk]. The result should be +0005.hk, -0004.hk Ah. One other thing. Can you explain what you're intending to do with this statement? A = file_contentsA.split(',') My thinking is I want to make both files as a list, so I can compare the two files. However, as you can see, it is only my wishful thinking. Best Henry On Fri, Jan 9, 2015 at 1:54 PM, Danny Yoo <d...@hashcollision.org> wrote: >> old_file = open('0105-up.txt','r') >> file_contentsA = old_file.read() >> A = file_contentsA.split(",") >> print(A) >> print() > > > Ah. One other thing. Can you explain what you're intending to do > with this statement? > > A = file_contentsA.split(',') > > The reason I ask is because neither of your input files that you've > shown us has a single comma in it, so I do not understand what the > intent is. _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/mailman/listinfo/tutor