perl -ne 'print if $h{$_}++ == 1' filename