Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: Re (tilly) 2: Golf challange: match U.S. State names

by cforde (Monk)
on Jun 06, 2001 at 03:48 UTC ( [id://86070]=note: print w/replies, xml ) Need Help??


in reply to Re (tilly) 2: Golf challange: match U.S. State names
in thread Golf challange: match U.S. State names

But the match isn't just on the names, but also on the abutment of names. I think you will get some false positives Eg. 'ZC' and 'OC' etc...

Have fun,
Carl Forde

Replies are listed 'Best First'.
Re: Re: Re (tilly) 2: Golf challange: match U.S. State names
by MeowChow (Vicar) on Jun 06, 2001 at 03:54 UTC
    Not so, the regex returns matches in pairs, ie:
    @list = 'foobarbazo' =~ /../g; # sets @list to ('fo','ob','ar','ba',' +zo')
       MeowChow                                   
                   s aamecha.s a..a\u$&owag.print
      Aaahhhh, I see. That's what I get for not testing it first.

      Have fun,
      Carl Forde

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others contemplating the Monastery: (4)
As of 2024-03-29 11:20 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found