subject

Alphabetic Telephone Number Translator Many companies use telephone numbers like 555-GET-FOOD so the number is easier for their customers to remember. On a standard telephone, the alphabetic letters are mapped to numbers in the following fashion: A, B, and C = 2 D, E, and F = 3 G, H, and I = 4 J, K, and L = 5 M, N, and O = 6 P, Q, R, and S = 7 T, U, and V = 8 W, X, Y, and Z = 9 Write a program that asks the user to enter a 12-character telephone number in the format: XXX-XXX-. Acceptable characters (X's) are A-Z and a-z. Your program should check for: The length of the phone number is correct. The dashes are included and are in the correct positions. There are no characters in the illegal characters in the string. The application should display the telephone number with any alphabetic characters that appeared in the original translated to their numeric equivalent. If the input string is not entirely correct then you should print an error message. For example, if the user enters 555-GET-FOOD the program should display 555-438-3663. If the user enters 123-456-7890, the program should display 123-456-7890. Rules: You must have one function (in addition to main()) that converts an alphabetic character to a digit. Or you can have one function that coverts all characters to digits. You can make your own function or use a built-in function if one exists.

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 12:10
2. fabulously fit offers memberships for$35 per month plus a $50 enrollmentfee. the fitness studio offersmemberships for $40 per month plus a$35 enrollment fee. in how many monthswill the fitness clubs cost the same? what will the cost be?
Answers: 1
question
Computers and Technology, 23.06.2019 16:10
What is the ooh? a. omaha occupation handbook b. online occupational c. occupations online d. occupational outlook handbook select the best answer from the choices provided
Answers: 3
question
Computers and Technology, 24.06.2019 01:00
Mastercard managers are motivated to increase (1) the number of individuals who have and use a mastercard credit card, (2) the number of banks and other clents who issue mastercards to customers and/or employees, and (3) the number of locations that accept mastercard payments. discuss how mastercard could use its data warehouse to it expand each of these customer bases.
Answers: 3
question
Computers and Technology, 24.06.2019 18:20
The following if statement contains a logic error, not a syntax error. rewrite it so that it is correct. assume the variable age already exists and holds a valid number. if (age == 18 & & age == 19) {
Answers: 1
You know the right answer?
Alphabetic Telephone Number Translator Many companies use telephone numbers like 555-GET-FOOD so the...
Questions
question
Mathematics, 13.01.2020 03:31
question
English, 13.01.2020 03:31
Questions on the website: 13722362