結果

問題 No.233 めぐるはめぐる (3)
ユーザー yaoshimaxyaoshimax
提出日時 2015-06-28 03:51:52
言語 PyPy2
(7.3.15)
結果
TLE  
実行時間 -
コード長 618 bytes
コンパイル時間 1,377 ms
コンパイル使用メモリ 77,556 KB
実行使用メモリ 98,680 KB
最終ジャッジ日時 2023-09-22 03:33:02
合計ジャッジ時間 5,742 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 194 ms
92,444 KB
testcase_01 AC 129 ms
88,340 KB
testcase_02 AC 107 ms
81,568 KB
testcase_03 AC 133 ms
89,264 KB
testcase_04 TLE -
testcase_05 -- -
testcase_06 -- -
testcase_07 -- -
testcase_08 -- -
testcase_09 -- -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

import itertools
boin=["i","a","a","e","u","u"]
siin=["n","b","m","g","r"]
N=int(raw_input())
S=[raw_input() for i in range(N)]
set(S)
for p in itertools.permutations(boin):
    for q in itertools.permutations(siin):
        for j in range(5):
            s=""
            for i in range(5):
                s+=q[i]
                s+=p[i]
                if i==j :
                    s+= p[5]
        if not (s in S):
            print s
            exit()
        s=p[5]
        for i in range(5):
            s+=q[i]
            s+=p[i]
        if not (s in S):
            print s
            exit()
print "NO"


0