concept str.translate ( ) method in category python
appears as: str.trslate() method

This is an excerpt from Manning's book Tiny Python Projects: Learn coding and testing with puzzles and games.
Can we use the
str.translate()method to solve this? I showed in chapter 4 how you could use a dictionary calledjumperto change a character like “1” to the character “9.” In this problem, we need to change all the lower- and uppercase vowels (10 total) to some givenvowel. For instance, to change all the vowels into the letter “o,” we could create a translation tabletlike so:t = {'a': 'o', 'e': 'o', 'i': 'o', 'o': 'o', 'u': 'o', 'A': 'O', 'E': 'O', 'I': 'O', 'O': 'O', 'U': 'O'}