Question: 15. Write a function CountDigitsAndAlpha that takes a string as input and print the number of digits in the string (i.e. '0', '1', '9')

15. Write a function CountDigitsAndAlpha that takes a string as input and 



15. Write a function CountDigitsAndAlpha that takes a string as input and print the number of digits in the string (i.e. '0', '1', '9') and the number of alphabet characters in the string (i.e. 'a', 'b', 'z', 'A', 'B', 'C',.. 'Z' ) For example, if the function takes the following string as input "There are 365 days in a non leap year, 7 days a weeks 52 weeks in a year,a month can have, 28,29, 30 or 31 days" its execution must print alphabetic characters There are 67 There are 14 digits [16].

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Answer Heres a Python function CountDigitsAndAlpha that takes a string as input ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!