Given a phrase from the user, write a program to capitalize the first and last letter of every word. Program Inputs ⢠Enter your phrase in lowercase: â User will always enter a string, no error checking needed. Program Outputs ⢠New phrase: XXX â Replace XXX with the corrected phrase
Sample Output Test Case 1: Enter your phrase in lowercase: this city needs me
New phrase: ThiS CitY NeedS ME
Test Case 2: Enter your phrase in lowercase: i do not like the cone of shame
New phrase: I DO NoT LikE ThE ConE OF ShamE
Test Case 3: Enter your phrase in lowercase: today is a good day to try
New phrase: TodaY IS A GooD DaY TO TrY
Test Case 4: Enter your phrase in lowercase: to infinity and beyond
New phrase: TO InfinitY AnD BeyonD
Test Case 5: Enter your phrase in lowercase: but only the fearless cab be great
New phrase: BuT OnlY ThE FearlesS CaN BE GreaT