[Tutor] help

Alan Gauld alan.gauld at freenet.co.uk
Wed Feb 9 23:05:15 CET 2005

> PhoneNumber and such, I cannot get it to put them in
> as a string? 

I can't help in general but I did notice...

> PhoneNumber = input("what is the phone number for the
> person you are adding? ")

You shouldn't store phone numbers as numbers.
People often include spaces or hyphens or parentheses etc 
when entering them, eg:

+44 (0) 1234 567890
(542) 123 4567

etc etc...

And of course you get the alpha numerics:


So strings are the best solution (and they should be 24 characters 
long to handle the worst case international standard phone number!)

Alan G.
Who works for the phone company! :-)

More information about the Tutor mailing list