Answer:
def w_count(s):
return(len(s.split()))
st=input('Enter a string:')
print("Number of words in given string=",w_count(st))
Step-by-step explanation:
6.5m questions
8.6m answers