Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In Java lang Standard telephone keypads contain the digits zero through nine. The numbers two through nine each have 3~4 letters (case insensitive) associated with

In Java lang

Standard telephone keypads contain the digits zero through nine. The numbers two through nine each have 3~4 letters (case insensitive) associated with them. Many people find it difficult to memorize phone numbers, so they use the correspondence between digits and letters to develop seven-letter words that correspond to their phone numbers. For example, a person whose telephone number is 686-2377 might remember it as "NUMBERS."

 Digit Letters 

2 ABC 3 DEF 4 GHI 5 JKL 6 MNO 7 PQRS 8 TUV

9 WXYZ

Each seven-letter word corresponds to exactly one seven-digit telephone number, but a seven-digit number corresponds to many seven-letter strings, most of which are not words.

Create a Project2 class under the project package.

In this project you will develop a program which will find all the corresponding English

words given any specific telephone number. Here are the detailed requirements:

In the Project2 class you will create a static void test() method.

The test method will first ask the user to type in through keyboard a 7-digit telephone

number.

If the number typed in by the user is not 7 digits or the number contains some number

of the digit 0 or 1, then your program reports an error and asks to type in another

number.

If the number typed in by the user is a 7-digit telephone number made up of the digits

2 through 9, then your program will print out all the English words corresponding to the telephone number (and the total number of them), using the given English word library in the COSC240_P2_EnglishWordList.txt.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Securing SQL Server Protecting Your Database From Attackers

Authors: Denny Cherry

1st Edition

1597496251, 978-1597496254

More Books

Students also viewed these Databases questions

Question

Find Io in the network shown using superposition 1KL2

Answered: 1 week ago

Question

2. Can you employ used equipment, or your business need new?

Answered: 1 week ago

Question

=+Identify the type of global assignment for which CCT is needed.

Answered: 1 week ago