📅  最后修改于: 2022-03-11 14:46:27.102000             🧑  作者: Mango
/** Displays an English letter's basic sound type. */
public static void englishPhonics(char letter) {
String sound; //letter's basic sound category
letter = Character.toUpperCase(letter);
switch (letter) {
case 'A':
case 'E':
case 'I':
case 'O':
case 'U': sound = "vowel"; break;
case 'B':
case 'C':
case 'D':
case 'G':
case 'K':
case 'P':
case 'Q':
case 'T':
case 'X': sound = "plosive"; break;
case 'F':
case 'H':
case 'V': sound = "fricative"; break;
case 'J': sound = "affricate"; break;
case 'M':
case 'N': sound = "nasal"; break;
case 'S':
case 'Z': sound = "sibilant"; break;
default: sound = "approximant";
}
System.out.println(letter + " is a(n) " + sound);
}