Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Correct Regex for reading stock symbol?

by kwaping (Priest)
on Jan 31, 2006 at 17:39 UTC ( #526815=note: print w/replies, xml ) Need Help??


in reply to Correct Regex for reading stock symbol?

Removed: I learn something new every day on this site! Thanks to samtregar for today's lesson.

I thought it had something to do with the unescaped period inside the brackets in the regex, but samtregar proved me wrong.
  • Comment on Re: Correct Regex for reading stock symbol?

Replies are listed 'Best First'.
Re^2: Correct Regex for reading stock symbol?
by samtregar (Abbot) on Jan 31, 2006 at 17:47 UTC
    Not true. Observe:

    $ perl -e 'print "broken\n" if "foo" =~ /[.]/' $ perl -e 'print "ok\n" if "foo." =~ /[.]/' ok

    The period is not magical inside a character class.

    -sam

Re^2: Correct Regex for reading stock symbol?
by dimar (Curate) on Jan 31, 2006 at 20:18 UTC
    Removed: I learn something new every day on this site!

    Unfortunately, nobody else gets to, because you removed the node instead of updating it. Please consider that next time, so others can get the full context of the thread and benefit in the mutual learning opportunity.


    =oQDlNWYsBHI5JXZ2VGIulGIlJXYgQkUPxEIlhGdgY2bgMXZ5VGIlhGV

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (8)
As of 2023-12-07 10:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What's your preferred 'use VERSION' for new CPAN modules in 2023?











    Results (32 votes). Check out past polls.

    Notices?