📅  最后修改于: 2022-03-11 14:52:07.214000             🧑  作者: Mango
final String vowels = "aeiou";
for(int i = yourString.length() - 1; i > 0; i--)
{
if(vowels.indexOf(yourString.toLowerCase().charAt(i)) >= 0)
{
System.out.println("The last vowel is : " + yourString.charAt(i));
break;
}
}