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

Re^2: Your favourite gory detail...

by Ido (Hermit)
on Jun 25, 2004 at 02:03 UTC ( [id://369534]=note: print w/replies, xml ) Need Help??


in reply to Re: Your favourite gory detail...
in thread Your favourite gory detail...

Took me about an hour to find code that has different output with and without that line... But it was fun;), so I won't spoil...

$foo='hello'; for(1..5){ $foo=~/(?=(.))/g; pos($foo)=pos($foo); print $1 }

"The additional state of being matched with zero-length is associated with the matched string, and is reset by each assignment to pos()."

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others surveying the Monastery: (6)
As of 2024-04-19 11:38 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found