Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: Returning _which_ pattern matched...?

by bikeNomad (Priest)
on Aug 03, 2001 at 08:06 UTC ( #101879=note: print w/replies, xml ) Need Help??


in reply to Returning _which_ pattern matched...?

No, it's quite simple. After the match, the variable $1 will be set to whatever matched your pattern -- which will be one of the three. Likewise for $2, etc. for later () sub-patterns. You'll still have to do something with that information, of course.
  • Comment on Re: Returning _which_ pattern matched...?

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (2)
As of 2023-04-01 14:12 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?