Given a phrase with one or more words, capitalize the first letter of each word and make the remaining letters all lowercase.

Example:

initialCap("hello karel") --> "Hello Karel"
initialCap("JAVA in hIgh SchOOl") --> "Java In High School"

This is in Java.

Respuesta :

Answer:

Is provided in the attached screenshot!

Explanation:

Steps taken:

1) Take input sentence and make it all lowercase

2) Split input sentence into separate words and store in an array

3) Go through each word and replace the first letter with the capital version of the letter

4) Combine each word back into a sentence.

5) Return the sentence

Ver imagen rainestormee