Company: Virtusa
Difficulty: easy
Consonant Vowel Merge You are given a string S of lowercase English letters that contains an equal number of vowels and consonants . Rearrange S into a new string of the same length such that: every even index 0, 2, 4, ... holds a consonant , every odd index 1, 3, 5, ... holds a vowel , the consonants appear in the same relative order as they appear in S , and the vowels appear in the same relative order as they appear in S . The vowels are a , e , i , o and u . Every other lowercase letter — including y — is a consonant (inferred — the source's own example rearranges beauty into betayu , which places y at index 4, an even position, so y is treated as a consonant) . Exactly one string satisfies all three conditions, so the answer is unique. Input Format A single line containing the string S . Output Format A single line containing the rearranged string. Constraints 2 <= |S| <= 17000 (inferred — the source states no numeric bound; the output is exactly as long as the input, so the