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

Re^2: Regex for extracting phone numbers from string

by dsheroh (Monsignor)
on Apr 11, 2016 at 07:32 UTC ( [id://1160095]=note: print w/replies, xml ) Need Help??


in reply to Re: Regex for extracting phone numbers from string
in thread Regex for extracting phone numbers from string

As yet another variation, 30 years ago, I lived in a rural area of the US where the population was small enough that, to make calls within the local exchange, you only had to dial the last four digits of the number. I assume that sort of thing is still around.

And there are obviously rules about which digits can be used and in what sequence, since that's the only way the phone switching system can determine when you've dialed the complete number, so not even every 7- or 10-digit number is a potential phone number. For example, 123-4567 can't be a valid phone number in the US because the leading '1' indicates that you're calling a non-local number.

  • Comment on Re^2: Regex for extracting phone numbers from string

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (6)
As of 2024-04-23 16:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found