Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re^5: Get a known substring from a string

by flowdy (Scribe)
on Sep 13, 2016 at 07:34 UTC ( [id://1171635]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    while ( ($p = index $haystack, $needle, $p+1) > -1 ) {
        # e.g. (not tested)
        pos($haystack) = $p;
    ...
            # regex doing the tough dishes
        ;   # /c flag: preserve pos() on non-match
    }
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (5)
As of 2024-04-19 22:36 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found