Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: Array Comparison

by Ovid (Cardinal)
on Dec 22, 2003 at 18:37 UTC ( [id://316439]=note: print w/replies, xml ) Need Help??


in reply to Array Comparison

Untested:

my @words = qw(foo bar baz quux Ovid); my @exclude = qw(bar Ovid); my %bad_words; @bad_words{@exclude} = @words[@exclude]; @words = grep { ! exists $bad_words{$_} } @words;

Cheers,
Ovid

New address of my CGI Course.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://316439]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (5)
As of 2024-03-28 15:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found