Using a temporary hash and List::MoreUtils:
use List::MoreUtils qw(all); use strict; use warnings; my @partial = qw(-true -depth=1); my @complete = qw (-search -depth=1 -true -expand_all); my %temp; @temp{@complete} = @complete; print "Yep\n" if all { exists $temp{$_} } @partial;
In reply to Re: Finding wether all elements of one array are in another
by tirwhan
in thread Finding wether all elements of one array are in another
by tsk1979
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |