Which of the following data types is most suitable for storing data that represents a phone number?
A phone number should be stored as a string because it is an identifier, may begin with zero, and can include nonnumeric formatting or country-code characters. Integer and float types are inappropriate because phone numbers are not arithmetic values; a char holds only one character.
Community Discussion