int LastVowel (string str) { int i, n ; char c ; n = StringLength(str) ; for (i = n - 1 ; i >= 0 ; i--) { c = IthChar(str, i) ; c = tolower(c) ; if (c == 'a' || c == 'e' || c == 'i' || c == 'o' || c == 'u') { return(i) ; } } /* No vowels found */ return(-1) ; }