#!/usr/bin/perl -w use strict; my @ar = qw/This this is a test test TEsT/; my @vals = uniq(@ar); $\ = "\n"; print (join " ", @vals); sub uniq { my %hash; return grep {!($hash{uc $_}++)} @_; }
In reply to Re: (almost) Unique elements of an array
by Anonymous Monk
in thread (almost) Unique elements of an array
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |