結果

問題 No.233 めぐるはめぐる (3)
ユーザー 👑 KazunKazun
提出日時 2021-07-16 19:59:39
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 442 ms / 1,000 ms
コード長 397 bytes
コンパイル時間 993 ms
コンパイル使用メモリ 87,124 KB
実行使用メモリ 98,372 KB
最終ジャッジ日時 2023-09-20 11:10:43
合計ジャッジ時間 9,875 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 423 ms
98,372 KB
testcase_01 AC 394 ms
97,328 KB
testcase_02 AC 376 ms
96,564 KB
testcase_03 AC 411 ms
96,104 KB
testcase_04 AC 425 ms
97,508 KB
testcase_05 AC 428 ms
97,496 KB
testcase_06 AC 433 ms
97,824 KB
testcase_07 AC 432 ms
97,440 KB
testcase_08 AC 433 ms
97,552 KB
testcase_09 AC 355 ms
96,976 KB
testcase_10 AC 352 ms
96,764 KB
testcase_11 AC 338 ms
90,160 KB
testcase_12 AC 419 ms
97,172 KB
testcase_13 AC 442 ms
97,256 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from itertools import permutations

N=int(input())
S=set()

for _ in range(N):
    S.add(input())

T=set()
for a in permutations(["i","a","a","e","u","u"]):
    for b in permutations(["n","b","m","g","r",""]):
        X=[""]*12
        for i in range(6):
            X[2*i  ]=b[i]
            X[2*i+1]=a[i]

        T.add("".join(X))

U=T-S

if U:
    x=U.pop()
    print(x)
else:
    print("NO")
0