Question
Write a Python program that asks the user for a number (an integer) and then asks for three (3) words one at a time. After
Write a Python program that asks the user for a number (an integer) and then asks for three (3) words one at a time. After receiving all three words, the program prints each of the input words if their length is a multiple of the first input number. Note: Python contains a len(x) function, which returns the number of characters in the argument string x. For example, if the user enters 3, kitten, rewards and cat, the program would output kitten and cat, because their lengths are each multiples of 3. (kitten has length 6 and cat has length 3). The word rewards, with length 7, would not be printed.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started