Answers for "Write a Python program using function concept that maps list of words into a list of integers representing the lengths of the corresponding words"

1

Write a Python program using function concept that maps list of words into a list of integers representing the lengths of the corresponding words

listOfWords = input('List of Word: ').split() 
listOfInts = []
 
for i in range(len(listOfWords)):
    listOfInts.append(len(listOfWords[i]))
     
print ("List of wordlength:"+str(listOfInts))
Posted by: Guest on December-02-2020

Code answers related to "Write a Python program using function concept that maps list of words into a list of integers representing the lengths of the corresponding words"

Python Answers by Framework

Browse Popular Code Answers by Language