in reply to How does one get only the non-redundant (non-repeating) entries with header?

Please learn to use Super Search for questions like this. FAQ-tully (or tutorial-ly), use a hash and the input record separator.

Done without checking the hash content-- that is, simply stuffing the latest match into the hash -- will give you output of the LAST unduplicated element of each datum. If you care about getting the first "sample\d", use the technique outlined by roboticus.


check Ln42!

  • Comment on Re: How does one get only the non-redundant (non-repeating) entries with header?
  • Download Code

Replies are listed 'Best First'.
Re^2: How does one get only the non-redundant (non-repeating) entries with header?
by supriyoch_2008 (Monk) on Jul 19, 2014 at 09:18 UTC

    Hi ww

    Thank you for your suggestions. I shall read the material and try to solve the problem. I am sorry for delayed reply as my internet connectivity is poor.