import sys
a=sys.argv[1]
b=sys.argv[2]
one=open(a,'rb').read()
two=open(b,"rb").read()
m=[]
ok=[]
for i in one.split("\n"):
if not i is "":
for j in two.split("\n"):
if not j is "":
if i == j:
ok.append(j)
else:
m.append(j)
print "====================[OK]"
print "\n".join(ok)
for i in ok:
sum=-1
for j in m:
sum=sum+1
if i == j:
m.pop(sum)
print "================[no]"
print "\n".join(list(set(m)))
转载于:https://my.oschina.net/u/1176204/blog/163919