# Use the following template. # Write a function that accepts a sentence input # in which all of the words are run together # but the first character of each word is uppercase. # Convert the sentence to a string in which # the words are separated by spaces # and only the first word starts an uppercase letter. # For example, the string "StudyAndDoMorePractice" # would be converted to "Study and do more practice" def convert_sentence(sentence): result = "" # write your code here return result # main in_sentence = "StudyAndDoMorePractice" expected_sentence = "Study and do more practice" test1 = convert_sentence(in_sentence) if test1 == expected_sentence: print("You correctly converted " + in_sentence + " to \"" + test1 + "\"") else: print("convert_sentence(" + in_sentence + ") should be \"" + expected_sentence + "\" + " " but you got \"" + test1 + "\". Please check your code.") in_sentence = "PythonIsFun" expected_sentence = "Python is fun" print(convert_sentence(in_sentence)) print(convert_sentence("ProblemSolvingSkillsNeedPractice"))