Not only is this incomprehensible, but the ink is ugly and the paper is from the wrong kind of tree.
-- Professor, EECS, George Washington University
Your array declaration is incorrect and unorderly. Whitespace scattered wildly, tabs not written as such... say rather
@ICE = ( "30F-WKS\t`1781183799.xxxx1'\tIC---;", "30F-WKS\t`1781183799.xxx11'\tIC---;", "ADM34A3F9\t`1781183799.41455'\tIC---;", );
The result you see in %seen indicates that your array @ICE contains 1218 elements, of which none is an array. The elements, if I get correctly what you mean by
30F-WKS (tab) `1781183799.xxx11' (tab) IC---;

are strings with tab separated fields. If you want to make each string into an array and check for uniqueness of their first element, you have to split them and make anonymous arrays of the first element from each split return, along with the original string as the second element, grep the list of anonymous arrays for definedness in %seen (that part of your code is correct) and finally extract the second element (which is the original string) from each anonymous array grep returns:

my @ICEU = map { $_->[1] } grep { !$seen{$_->[0]}++ } map { [ (split / +\t/, $_)[0], $_ ] } @ICE;

Always use -w!

Your second declaration of @ICEU with my masks the first one.

--shmem

_($_=" "x(1<<5)."?\n".q·/)Oo.  G°\        /
                              /\_¯/(q    /
----------------------------  \__(m.====·.(_("always off the crowd"))."·
");sub _{s./.($e="'Itrs `mnsgdq Gdbj O`qkdq")=~y/"-y/#-z/;$e.e && print}

In reply to Re: remove duplicates from an array! by shmem
in thread remove duplicates from an array! by nashkab

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.