http://qs321.pair.com?node_id=1002832


in reply to min and mindex

Y'all are messing with my PerlMonks drinking game: No one said Schwartzian transform, e.g.,

#!/usr/bin/env perl use Modern::Perl; my ($c, $d, $i) = ([qw(7 5 3 0 9 18 12)], [qw(a b c d e f g)], 0); say $d->[[(sort {$a->[0]<=>$b->[0]} map {[$_,$i++]} @{$c})]->[0][1]];