Write a python program to print only even length words in a sentence


Topic: Write a python program to print only even length words in a sentence

Solution

def printEvenLengthWords(s):       
    s = s.split(' ')  
    for word in s:
        if len(word)%2==0: 
            print(word)  
			



List all Python Programs