Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: little regex question

by VGavara (Novice)
on Aug 01, 2013 at 10:51 UTC ( #1047421=note: print w/ replies, xml ) Need Help??


in reply to Re: little regex question
in thread little regex question

Just note the difference between these two regular expressions:

[^a]at

Your regex, will match any expression with three characters where the first one is not 'a' and the rest is 'at'

[^a]?at

The regex you would expect, will match any expression ending with 'at' and starting AT MOST (repetition operator ?) by any character not being 'a'

Not the suitable place to post it since it seems I'm answering to Loops, sorry. The response was directed to anaconda

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (9)
As of 2016-07-29 17:51 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What is your favorite alternate name for a (specific) keyboard key?


















    Results (264 votes). Check out past polls.