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

Re: regexp golf - homework

by LanX (Canon)
on Dec 11, 2012 at 06:45 UTC ( #1008218=note: print w/ replies, xml ) Need Help??


in reply to regexp golf - homework

Ehm ... what am I missing here? like IMHO just searching for a repeated digit like with /(\d).*\1/ and inverting the result should do.

DB<111> print $_ !~ /(\d).*\1/ ? "$_ ok\n" :"$_ has <$1>\n" for qw/0 +12 0102 01233/ 012 ok 0102 has <0> 01233 has <3>

Cheers Rolf


Comment on Re: regexp golf - homework
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (8)
As of 2014-09-19 08:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (133 votes), past polls