Search a list of records: Difference between revisions

m
fix mislabled language block
m (Fix Perl 6 -> Raku links)
m (fix mislabled language block)
Line 1,828:
The CPAN module <tt>List::MoreUtils</tt> provides the <tt>first_index</tt> function which could be used to write that first case more elegantly:
 
<lang perl6perl>use List::MoreUtils qw(first_index);
 
$index1 = first_index { $_->{name} eq 'Dar Es Salaam' } @cities;</lang>
10,333

edits