Question: Using the string commands introduced in Lab 2, write a Python program that prompts the user for a three-word phrase separated by comma (,). Create

Using the string commands introduced in Lab 2, write a Python program that prompts the user for a three-word phrase separated by comma (,). Create a new phrase, where those three words are separated by spaces and in reversed order. That is, the first word in the input phrase is the last word in the new phrase while the third word in the input phrase is the first word in the new phrase. Print new phrase in upper case letters and lower case letters.

A sample run of your program should look like:

Enter three words separated by comma (,): One,Two,Three new string: Three Two One lower case: three two one upper case: THREE TWO ONE 

Another run:

Enter three words separated by comma (,): Big,Medium,Small new string: Small Medium Big lower case: small medium big upper case: SMALL MEDIUM BIG 

Hint: Your program should be able to take any phrase the user enters and prints it, it in upper case letters, and it in lower case letters. To do that, you need to store the phrase in a variable and print variations of the stored variable. You also need to find those three words from the resulting list after applying split method on the input string. Then concatenate those words to get a new phrase.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!