matching a street address with regular expressions

Grant Edwards grante at visi.com
Fri Oct 12 15:29:34 EDT 2007


On 2007-10-12, Paul McGuire <ptmcg at austin.rr.com> wrote:

> I've been to Japan and Europe too, and I can't even figure out
> how many digits a phone number is supposed to have!

I was shocked at utterly foreign and lost I felt looking at
phone numbers in various places overseas.  I could deal with
phone numbers having other than 7/10 digits and being
punctuated differently, but in some places the number of digits
in a phone number is apparently random. Even among phone
numbers of the same length, the formatting (where the
spaces/hyphens) go, seems to be more-or-less random.

[Here in the US, a phone number is always the same length: 10
digits (though you only have to dial the first 3 if they're
different than your own).  Back in the pre-cellular days, given
just the first two digits of a phone number, you even knew
whether it was going to be all 10 digits or just 7.]

People speaking a different language was fine.  Driving on the
other side of the road was fine.  Colorful money with
rediculous exchange rates was fine.  Daytime being the wrong
length was definitely strange. But, phone numbers not having a
fixed length and format?  That's utter madness!

-- 
Grant Edwards                   grante             Yow! Oh my GOD -- the
                                  at               SUN just fell into YANKEE
                               visi.com            STADIUM!!



More information about the Python-list mailing list