Jul-25-2022, 03:34 PM
This example joins all the words without spaces
words = input("Enter text: ").split() print(len(''.join(words) / len(words))This example sums the lengths of each word.
words = input("Enter text: ").split() print(sum(map(len, words)) / len(words))