please solve it as Python, use recursion
Function Name: numVowels() Parameters: list of names ( list) Returns: dictionary mapping names to number of vowels ( dict ) Description: At the end of the semester, you want to figure out how many vowels are in the names of some of your friends. Return a dictionary containing the name of the TAs as the keys mapped to how many vowels there are in each name. Note: You can use loops to count the number of vowels in the names_, but you must use recursion to create your dictionary. Note: This problem is case insensitive, so and are treated as the same and should be included in the number of vowels. ≫> numVowels (["Anupama", "Coco", "Rod", "Fiona"]) \{'Fiona': 3, 'Rod': 1, 'Coco': 2, 'Anupama': 4\} ≫> numVowels (["Michael", "Carol", "Paris"]) { 'Paris': 2, 'Carol': 2, 'Michael': 3}
please solve it as Python, use recursion
-
answerhappygod
- Site Admin
- Posts: 899604
- Joined: Mon Aug 02, 2021 8:13 am
please solve it as Python, use recursion
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!