Skip to content

Commit 85d7c8b

Browse files
authored
Merge pull request #387 from Prajithp/master
Remove Duplicates from Array using Perl5
2 parents 90b9446 + c4d0713 commit 85d7c8b

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

perl/remove_duplicates.pl

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/usr/bin/perl
2+
3+
my @array = (1,10,7,1,4);
4+
my @unique = keys {map {$_ => 1} @array};
5+
print @unique;

0 commit comments

Comments
 (0)