VowelLatin
SRM 336 · 2007-01-25 · by dgoodman
Problem Statement
Vowels are defined to be the letters 'a', 'e', 'i', 'o', and 'u' (in either uppercase or lowercase). The reordering of the letters in a word does not change their case. So the Vowel Latin version of "AmplifierX" would be "mplfrXAiie"
Create a class VowelLatin that contains a method translate that is given a
Constraints
- word contains between 1 and 50 characters, inclusive.
- Each character in word is a letter ('A'-'Z', 'a'-'z').
"XYz" Returns: "XYz"
The word contains no vowels so it is unchanged by translating to Vowel Latin.
"application" Returns: "pplctnaiaio"
The 5 vowels in this word are all moved to the end of the word.
"qwcvb" Returns: "qwcvb"
"aeioOa" Returns: "aeioOa"
"i" Returns: "i"
Submissions are judged against all 22 archived test cases, of which 5 are shown here. Case numbers match the judge’s.
Language: C++17 · define a public class VowelLatin with a public method string translate(string word) · 22 test cases · 2 s / 256 MB per case