Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^4: Help please

by davidrw (Prior)
on Apr 26, 2008 at 03:46 UTC ( #683023=note: print w/replies, xml ) Need Help??


in reply to Re^3: Help please
in thread Help please

Here's two different ways:

One way is that you could capture the character class match with parens, and then refer to it (in this case) as $2.
/it (.*)([.?,])$/i and print $1, $2, $/;

Another way would be to simply move the character class to be inside the existing capturing parens:
/it (.*[.?,])$/i and print $1, $/;

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://683023]
help
Chatterbox?
[LanX]: well I gimp ed a while to make it look natural
[LanX]: ... obviously too long
[Eily]: I yes, the natural onion in the flamming eye, I know what you mean
[LanX]: Eily your turn to provide a pic :)
[Eily]: occupe toi de tes oignons
LanX could do a zoom out in animated gif ...
[LanX]: heh
[marto]: get with the times, webm :P
[LanX]: didn't know this expression xD
[Eily]: :)

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (10)
As of 2017-12-14 16:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What programming language do you hate the most?




















    Results (398 votes). Check out past polls.

    Notices?