Question: Python. #4-5 4. Word count. Write a program that counts the words in a sentence. Call the program wordCount. For example, if the user enters
4. Word count. Write a program that counts the words in a sentence. Call the program wordCount. For example, if the user enters the sentence "The quick brown fox jumps over the lazy dog". the output should be 9. Allow the user to enter 3 different sentences. 5. Word average. Write a program that averages length of the words in a sentence. Call the program wordAverage. For example, if the user enters the sentence "The quick brown fox jumps over the lazy dog" initially the output should be 3.88888888889. Use string formatting to insure that the average is output centered in a space of 10 characters with 3 of those characters after the decimal. Allow the user to enter 3 different sentences
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
