XP is just a number | |
PerlMonks |
chopping lots of charactersby Anonymous Monk |
on Jun 24, 2004 at 11:35 UTC ( [id://369291]=perlquestion: print w/replies, xml ) | Need Help?? |
Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question: Hi, Quick and easy question i'm sure, but how can I chop off the last 4 characters from a string using chop. I can do this:
Thats a little bit ugly though. I realise I can probably use substr, but wondered if there was a cool way to do it with chop. Thanks,
Back to
Seekers of Perl Wisdom
|
|