Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: removing a sublist

by Cristoforo (Deacon)
on Apr 21, 2012 at 15:28 UTC ( #966378=note: print w/ replies, xml ) Need Help??


in reply to removing a sublist

List::Compare will also solve this problem.

#!/usr/bin/perl use strict; use warnings; use 5.014; use List::Compare; my @winners=("ruth","sheila"); my @correct=("ruth","martin","dee","zack"); my $lc = List::Compare->new(\@winners, \@correct); my @composite = $lc->get_Ronly; print "@composite\n";
Prints
dee martin zack

Chris


Comment on Re: removing a sublist
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (5)
As of 2014-08-29 03:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (275 votes), past polls