Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked

Re: search, replace and backrefrences

by Helter (Chaplain)
on Sep 30, 2002 at 17:46 UTC ( #201782=note: print w/replies, xml ) Need Help??

in reply to search, replace and backrefrences

After some more reading I found that my first assumption is only half true.
$1-$9 are ALWAYS backrefrences, where $10 and up are only backrefrences if more than 10 parens were used.
This mixes with the comments about a variable that starts with a digit, can only have digits.

So $10 is taken as the whole name of a variable (undefined)
$1_ gets treated like $1 because _ is not a digit.

Thanks for all the help, I'm slowly understanding the subtle nature of Perl :)

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://201782]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (3)
As of 2022-01-28 05:36 GMT
Find Nodes?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:

    Results (73 votes). Check out past polls.