Question: Two function definitions are saved in the same file: A function count _ vowels has one parameter, a word, and returns the number of vowels
Two function definitions are saved in the same file:
A function countvowels has one parameter, a word, and returns the number of vowels in that word.
A function countconsonants has one parameter, a word, and returns the number of consonants in that word.
To determine the number of letters in a word, write a oneline body for the following function that calls both countvowels and countconsonants:
def countlettersword:
str int
Return the number of letters in word.
countlettershello
countlettersbonjour
# Write the oneline function body that belongs here.
Note:
do not call any functions other than those listed above
do not use any unnecessary parentheses
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
