def reverseVowels(s):
vowels = 'aeiou'
string = list(s)
left, right = 0, len(s) - 1
while left < right:
if string[left].lower() not in vowels:
left += 1
elif string[right].lower() not in vowels:
right -= 1
else:
string[left], string[right] = string[right], string[left]
left += 1
right -= 1
return ''.join(string)