Use compress-function to remove vowels, then substr to get the first three chars.
consonants = substr(compress(word, 'aeiou', 'i'), 1, 3);
if you are 100% sure that you have only upcase letters in your list, than use
consonants = substr(compress(word, 'AEIOU'), 1, 3);
... View more