Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Allow a user to enter a phone number as a string that contains letters. Then convert the entire phone number into all numbers. For example:
Allow a user to enter a phone number as a string that contains letters. Then convert the entire phone number into all numbers. For example:
1-800-Flowers as an input would be displayed as 1-800-356-9377
You must create a method that accepts a char and returns an int. Pass one character at a time to the method using charAt() inside a loop in main.
No input or output statements are allowed in the method.
use Netbeans
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started