file comparison

Hendrik van Rooyen hendrik at
Fri Jul 31 06:47:30 EDT 2009

On Friday 31 July 2009 11:25:17 learner learner wrote:
> Hi all,
> I want to compare two text files line by line and eliminate the
> matching/repeated line and store the unmatched/leftout lines into a third
> file or overwrite into one of them.

This is not as simple as it seems.

You will probably be better off using diff, or,
if it is a learning exercise, studying its source.

- Hendrik

More information about the Python-list mailing list