You can see, it is similar to my for_block which was benchmarked.sub first (&@) { my $code = shift; foreach (@_) { return $_ if &{$code}(); } undef; }
In reply to Re: Re: The fastest way of searching a certain element in an array
by ccn
in thread The fastest way of searching a certain element in an array
by ccn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |