import java.util.HashSet; import java.util.Scanner; import java.util.Set; public class Main_yukicoder233 { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); hs = new HashSet(); for (int i = 0; i < n; i++) { String s = sc.next(); hs.add(s); } used = new boolean[si.length]; perm = new int[si.length]; permutation(0, si.length); System.out.println("NO"); sc.close(); } static Set hs; static char[] si = {'n', 'b', 'm', 'g', 'r'}; static char[] bo = {'i', 'a', 'a', 'e', 'u', 'u'}; static boolean[] used; static int[] perm; static boolean[] used2; static int[] perm2; // {0, 1, 2, 3, ...., n - 1}の並び替えn!通りを生成する static void permutation(int pos, int n) { if (pos == n) { used2 = new boolean[bo.length]; perm2 = new int[bo.length]; permutation2(0, bo.length); return; } // perm[]のpos番目を0~n-1のどれにするかのループ for (int i = 0; i < n; i++) { if (!used[i]) { perm[pos] = i; // iを使ったのでフラグをtrue used[i] = true; permutation(pos + 1, n); // 戻ってきたらフラグを戻す used[i] = false; } } return; } // {0, 1, 2, 3, ...., n - 1}の並び替えn!通りを生成する static void permutation2(int pos, int n) { if (pos == n) { // perm[] に対する操作 StringBuilder sb = new StringBuilder(); for (int i = 0; i < si.length; i++) { sb.append(si[perm[i]]); sb.append(bo[perm2[i]]); } for (int i = 0; i < si.length; i++) { StringBuilder tmp = new StringBuilder(sb); tmp.insert(i * 2, bo[perm2[bo.length - 1]]); if (!hs.contains(tmp.toString())) { System.out.println(tmp); System.exit(0); } } return; } // perm[]のpos番目を0~n-1のどれにするかのループ for (int i = 0; i < n; i++) { if (!used2[i]) { perm2[pos] = i; // iを使ったのでフラグをtrue used2[i] = true; permutation2(pos + 1, n); // 戻ってきたらフラグを戻す used2[i] = false; } } return; } }