Question: 21. Assume that the Python variable sentence holds a string that contains a series of words, separated by single spaces. Write a few lines of
21. Assume that the Python variable sentence holds a string that contains a series of words, separated by single spaces. Write a few lines of Python code that will print out every second word in sentence, and NOTHING ELSE. For example, if sentence held the string "I am the very model of a modern major general", your code would print out am very of modern general Hint: is there a Python function that will help you to break up a string into individual words
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
