in reply to Re: Removing repeated lines from file
in thread Removing repeated lines from file

Of course, in reality the problem is un-solvable. A decision needs to be made in order to amend the problem statement and render a solvable problem. Which one of the N copies of any particular duplicate line should be preserved?
  • Comment on Re: Re: Removing repeated lines from file

Replies are listed 'Best First'.
Re: Re: Re: Removing repeated lines from file
by Anonymous Monk on Jun 25, 2003 at 16:01 UTC
    Hm yes I was thinking the same thing: if the order is important, so is the decision about which one to throw away. Also, in the sample code that matth provides, he's pulling his input lines apart and categorizing them in some way that makes sense only to him, and might be useful for others to know about.

    Can we see some sample input?