import java.util.*; public class Main { static HashSet set; static char[] moji = {'i', 'n', 'a', 'b', 'a', 'm', 'e', 'g', 'u', 'r', 'u'};//11moji static char[] now = new char[11]; static int used = 0; static int current = 0; static void func(boolean prevNotVowel) { if (current == 11) { if (!set.contains(new String(now))) { System.out.println(now); System.exit(0); } else { return; } } if (current >= 6 && !prevNotVowel) { if ((used & 0b10101010101) == 0b10101010101) { return; } } for (int i = 0; i < 11; i++) { if ((used >> i & 1) > 0) { continue; } boolean isNotVowel = ((1 << i) & 0b01010101010) > 0; if (prevNotVowel && isNotVowel) { continue; } // if (((used >> 2 & 1) == 0 && (used >> 4 & 1) > 0) || ((used >> 8 & 1) == 0 && (used >> 10 & 1) > 0)) // return; now[current] = moji[i]; used |= 1 << i; current++; func(isNotVowel); current--; used &= ~(1 << i); } } public static void main(String[] args) { Scanner sc = new Scanner(System.in); int N = sc.nextInt(); set = new HashSet<>(N); for (int i = 0; i < N; i++) set.add(sc.next()); func(false); System.out.println("NO"); } }