Beefy Boxes and Bandwidth Generously Provided by pair Networks Frank
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

(bbfu) Re(4): pattern matching on a single line

by bbfu (Curate)
on Jun 05, 2001 at 19:33 UTC ( [id://85965]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Re: Re: Re: pattern matching on a single line
in thread How do I store all matches from a single line?

The return value of m/()/g in array context (which map evaluates EXPR in) is the array containing all the matches inside the parentheses, just like in your first reply. The only difference that the map makes is that merlyn is evaluating the m/()/g for every line, while yours only did one line.

HTH.

bbfu
Seasons don't fear The Reaper.
Nor do the wind, the sun, and the rain.
We can be like they are.

Replies are listed 'Best First'.
Re: (bbfu) Re(4): pattern matching on a single line
by FouRPlaY (Monk) on Jun 05, 2001 at 19:44 UTC
    Gotcha, I just needed to be more clear. I thought it was implied that they'd have to use that line of code in a loop over each line. I'll make sure I'm more specific next time. Thanks.



    FouRPlaY
    Learning Perl or Going To die() Trying

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://85965]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.