• About: I blog about Perl.
  • Commented on Day 2: When uniq is not unique enough (App::nauniq)
    I think the easiest way to keep first occurrence of each line is one of: $ awk '!a[$0]++' input.txt or $ perl -ne'$h{$_}++||print' input.txt To keep the last occurrence is enough use command tac in input.txt before awk or perl...
Subscribe to feed Recent Actions from jimmy.tty

Subscribe to feed Responses to Comments from jimmy.tty

About is a common blogging platform for the Perl community. Written in Perl and offering the modern features you’ve come to expect in blog platforms, the site is hosted by Dave Cross and Aaron Crane, with a design donated by Six Apart, Ltd.