Open('3rd', 'w').writelines(set(open('2nd').readlines())-set(open('1st')))

2008/5/29, loial <[EMAIL PROTECTED]>:
> I have a requirement to compare 2 text files and write to a 3rd file
> only those lines that appear in the 2nd file but not in the 1st file.
>
> Rather than re-invent the wheel I am wondering if anyone has written
> anything already?
>
> --
> http://mail.python.org/mailman/listinfo/python-list
>


-- 
mvh Björn
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to