Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

*****Requiremrnt: 1. Please do not use any array or arraylist 2. collects only a single String input 3. uses at least 3 String methods 1)

*****Requiremrnt: 1. Please do not use any array or arraylist 2. collects only a single String input 3. uses at least 3 String methods

image text in transcribed

1) Just Initials: Print just the initials in upper case letters separated by periods 2) Last Name First With Middle Initial: Print the last name in lower case with the first letter capitalized, followed by a comma and the first name in in lower case with the first letter capitalized and then the middle initial capitalized followed by a period 3) First and Last Name Only. Print the just the first name followed by the last name - all names with first letter capitalized Note: Your program has to check for middle name and if the user does not have a middle name your program has to print the variations without the middle name. See the sample output below Important: You will not get points if you do not read the string as one line (Use the nextLine0 method, not the next0 method). You cannot use the Scanner class to extract different parts of the name. You have to use the methods in String class Sample Output, with user input in red Sample run 1 What are your first, middle and last names ? Ada Lovelace Initials Last Name First Lovelace, Ada First and LastAda Lovelace Sample run 2 What are your first, middle and last names ? SALLY rachel riDE Initials Last Name First Ride, Sally R First and Last : Sally Ride :S.R. R

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

Step: 3

blur-text-image

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

More Books

Students also viewed these Databases questions