จงเขียนฟังก์ชั่นที่รับ string เข้าไปแล้ว ส่งค่า index ของสระตัวแรกใน string นั้นออกมา (a,e,i,o,u)
Examples
firstVowel(“apple”) ➞ 0
firstVowel (“hello”) ➞ 1
firstVowel (“strawberry”) ➞ 3
จงเขียนฟังก์ชั่นที่รับ string เข้าไปแล้ว ส่งค่า index ของสระตัวแรกใน string นั้นออกมา (a,e,i,o,u)
Examples
firstVowel(“apple”) ➞ 0
firstVowel (“hello”) ➞ 1
firstVowel (“strawberry”) ➞ 3