On Tue, Jul 3, 2012 at 6:44 AM, Chris Stinemetz
<chrisstinem...@gmail.com> wrote:
> On Tue, Jul 3, 2012 at 5:11 AM, xiyoulaoyuanjia
> <xiyoulaoyuan...@gmail.com> wrote:
>> hi Rob 。 i do not know  what the 'for' meaning in    print $_->[0], "\n" for
>> sort { $b->[1] <=> $a->[1] } @RNC;
>> can you give me mush information about this use 。
>> 3ks !
>>
>
> I believe xiyoulaoyuan...@gmail.com intended to send this question to the 
> list.

I will take a stab at explaining it.

The "for" is just a loop construct that is using the 2nd sorted
element of the anonymous array as a reference point to print each
record (first element in the anonymous array) in the desired order.

-Chris

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to