Question: Using Python WITHOUT USING THE COUNT FUNCTION consonantCount (s) Write the function consonantCount that counts how many times a consonant (either lowercase or uppercase) occurs
Using Python WITHOUT USING THE COUNT FUNCTION
consonantCount (s)
Write the function consonantCount that counts how many times a consonant (either lowercase or uppercase) occurs in a string. It takes a string s as input and returns an integer, the number of consonants in the string. For this question, y and Y are not consonants. Please use a for loop to do the computation. Please do not use a brute force solution (comparing against one consonant at a time): it will not receive credit.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
