Show the user a list of the names (with integers before each name). Allow the user to select which friend is his/her best friend. Write in java and use test case examples as a result.

Programming with Microsoft Visual Basic 2017
8th Edition
ISBN:9781337102124
Author:Diane Zak
Publisher:Diane Zak
Chapter7: String Manipulation
Section: Chapter Questions
Problem 15E
icon
Related questions
Question
Show the user a list of the names (with integers before each name). Allow the user to select which friend is his/her best friend. Write in java and use test case examples as a result.
Test Case 3
Enter five names n
Enter friend 1\n
Fred ENTER
Enter friend 2 \n
Bill ENTER
Enter friend 3 \n
Tom ENTER
Enter friend 4 \n
Frank ENTER
Enter friend 5 \n
Elon ENTER
Here are all of those names \n
Friend 1 is Fred \n
Friend 2 is Bill \n
Friend 3 is Tom \n
Friend 4 is Frank \n
Friend 5 is Elon \n
Which friend is your best friend? (Enter an integer) \n
5 ENTER
Elon? Yes, Elon is awesome|\n
Transcribed Image Text:Test Case 3 Enter five names n Enter friend 1\n Fred ENTER Enter friend 2 \n Bill ENTER Enter friend 3 \n Tom ENTER Enter friend 4 \n Frank ENTER Enter friend 5 \n Elon ENTER Here are all of those names \n Friend 1 is Fred \n Friend 2 is Bill \n Friend 3 is Tom \n Friend 4 is Frank \n Friend 5 is Elon \n Which friend is your best friend? (Enter an integer) \n 5 ENTER Elon? Yes, Elon is awesome|\n
Test Case 1
Enter five names \n
Enter friend 1 \n
Fred ENTER
Enter friend 2 \n
Bill ENTER
Enter friend
\n
Tom ENTER
Enter friend 4 \n
Frank ENTER
Enter friend 5 \n
Elon ENTER
Here are all of those names \n
Friend 1 is Fred \n
Friend 2 is Bill \n
Friend 3 is Tom \n
Friend 4 is Frank \n
Friend 5 is Elon \n
Which friend is your best friend? (Enter an integer) \n
3 ENTER
Tom? Yes, Tom is awesome \n
Test Case 2
Enter five names \n
Enter friend 1\n
Fred ENTER
Enter friend 2 \n
Bill ENTER
Enter friend 3 \n
Tom ENTER
Enter friend 4 \n
Frank ENTER
Enter friend 5 \n
Elon ENTER
Here are all of those names \n
Friend 1 is Fred \n
Friend 2 is Bill \n
Friend 3 is Tom \n
Friend 4 is Frank \n
Friend 5 is Elon \n
Which friend is your best friend? (Enter an integer) \n
1 ENTER
Fred? Yes, Fred is awesome \n
Transcribed Image Text:Test Case 1 Enter five names \n Enter friend 1 \n Fred ENTER Enter friend 2 \n Bill ENTER Enter friend \n Tom ENTER Enter friend 4 \n Frank ENTER Enter friend 5 \n Elon ENTER Here are all of those names \n Friend 1 is Fred \n Friend 2 is Bill \n Friend 3 is Tom \n Friend 4 is Frank \n Friend 5 is Elon \n Which friend is your best friend? (Enter an integer) \n 3 ENTER Tom? Yes, Tom is awesome \n Test Case 2 Enter five names \n Enter friend 1\n Fred ENTER Enter friend 2 \n Bill ENTER Enter friend 3 \n Tom ENTER Enter friend 4 \n Frank ENTER Enter friend 5 \n Elon ENTER Here are all of those names \n Friend 1 is Fred \n Friend 2 is Bill \n Friend 3 is Tom \n Friend 4 is Frank \n Friend 5 is Elon \n Which friend is your best friend? (Enter an integer) \n 1 ENTER Fred? Yes, Fred is awesome \n
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 2 images

Blurred answer
Knowledge Booster
Top down approach design
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Programming with Microsoft Visual Basic 2017
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning
Np Ms Office 365/Excel 2016 I Ntermed
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:
9781337508841
Author:
Carey
Publisher:
Cengage
COMPREHENSIVE MICROSOFT OFFICE 365 EXCE
COMPREHENSIVE MICROSOFT OFFICE 365 EXCE
Computer Science
ISBN:
9780357392676
Author:
FREUND, Steven
Publisher:
CENGAGE L
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage