I've never needed to use chop(), so I not really fussed about its disappearance or not, but this does give me the opportunity to mention my great wish for Perl6.
Please let me treat my strings as arrays of char!
Yes, I know I could probably write a module, Maybe use Overload; (can it handle operators that are paired []?) or just split to an array and then join (or unpack & pack; or substr as Rvalue and Lvalue) etc., but it would be so useful sometimes to be able to say $string[n]... which, with Perl6's new treatment of sigil's would no longer be ambiguous.
Then chop (getting smoothly back on topic:) simply becomes $#string-- or whatever $# will be in the new money.
Well It's better than the Abottoire, but Yorkshire!
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.