in reply to Re^2: Duplicate lines with spaces, tabs...
in thread Duplicate lines with spaces, tabs...

Maybe you didn't copy the entire example, including the blank lines. This is my result.
5 6 55 66
Apparantly perlmonks.org doesn't show blank lines. But after '66' I get a new blank line.

Replies are listed 'Best First'.
Re^4: Duplicate lines with spaces, tabs...
by massa (Hermit) on Jul 17, 2008 at 14:23 UTC
    I used:
    $ perl -i.bak -lne 's/\A\s+//; s/\s+\Z//; next unless $_ and not $seen +{$_}++; print' input.txt
    And I didn't get empty trailing lines...
    []s, HTH, Massa
Re^4: Duplicate lines with spaces, tabs...
by marto9 (Beadle) on Jul 17, 2008 at 15:51 UTC
    Nvm. The problem isn't that big. I wish to thank everyone that helped me. ;)