Respected Monks,
I am not sure if its a right place to post this but its something I observed while reading through and I guess it might need correction if at all I am right.
In perlfaq,under the topic
How do I sort an array by (anything)?
Supply a comparison function to sort() (described in sort):
1. @list = sort { $a <=> $b } @list;
The default sort function is cmp, string comparison, which would sort (1, 2, 10) into (1, 10, 2) . <=> , used above, is the numerical comparison operator.
Shouldn't it say
"would sort (1, 10, 2) into (1, 2, 10)"
All said and done but I must admit about perl that I have not come across any other language (of course out of a handful which I boast I know) that has such an extensive documentation categorized in such a pretty way and accessible in so many ways :)
/zoop
'When You starve With A Tiger, The Tiger always starves last'
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.