use strict; use List::AssignRef; use List::MoreUtils qw( part ); my @not_sorted = qw(Ape Arg Beep Circus); (deref my @trash, deref my @A) = part { !!/^A/ } sort @not_sorted; print "Got A: @A\n"; print "Got trash: @trash\n";
In reply to Re: Array splitting
by tobyink
in thread Array splitting
by Hopfi
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |