in reply to When you first encountered Perl, which feature amazed you the most?

Coming from C, hashes were the feature that I liked best at the beginning. But now (after some time using perl for automating my tasks) I think that the simple way to use RegExes is the best. I love that!

  • Comment on Re: When you first encountered Perl, which feature amazed you the most?

Replies are listed 'Best First'.
Re^2: When you first encountered Perl, which feature amazed you the most?
by cavac (Prior) on Mar 05, 2025 at 13:37 UTC

    That, and the feature that you don't have to wrangle data types all the time. I don't mean the usual scalar/array/hash/ref thing in Perl. But more on the "oh, you want bigger numbers? Oh you want signed numbers?" side of things, like having to rewrite larger parts of the codebase because suddenly your database ID's need 64 bits instead of 32 bits...

    PerlMonks XP is useless? Not anymore: XPD - Do more with your PerlMonks XP
    Also check out my sisters artwork and my weekly webcomics
Re^2: When you first encountered Perl, which feature amazed you the most?
by bliako (Abbot) on Mar 09, 2025 at 17:55 UTC
    the simple way to use RegExes is the best

    Come to think about it, this is still correct today when lots of other languages offer regex but none with the ease (basically zero setup code!) of Perl's. And if they do, they are copying from the original anyway. Enclosing regexes in quotes (in other languages) is another frustration of mine because I get this primordial feeling that some unwanted interpolation happened or I missed some necessary escape. Whereas Perl's / / / is comfort of mind. Perl's enclosing regexes with "any" character is an added bonus.

    Perl, when it came up, offered exactly what the masses (never realised they) wanted and how they (never realised they) wanted it. The masses realised that what they got was exactly what AND how they would have wanted if they had the far-sightness of Perl's founders.