結果
問題 | No.233 めぐるはめぐる (3) |
ユーザー | Tsubajiro |
提出日時 | 2022-05-19 00:31:28 |
言語 | Python3 (3.12.2 + numpy 1.26.4 + scipy 1.12.0) |
結果 |
TLE
|
実行時間 | - |
コード長 | 690 bytes |
コンパイル時間 | 112 ms |
コンパイル使用メモリ | 11,832 KB |
実行使用メモリ | 22,636 KB |
最終ジャッジ日時 | 2023-10-17 06:09:00 |
合計ジャッジ時間 | 6,416 ms |
ジャッジサーバーID (参考情報) |
judge14 / judge12 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 289 ms
22,140 KB |
testcase_01 | AC | 201 ms
21,044 KB |
testcase_02 | AC | 111 ms
14,776 KB |
testcase_03 | AC | 215 ms
21,044 KB |
testcase_04 | AC | 304 ms
22,636 KB |
testcase_05 | AC | 485 ms
22,636 KB |
testcase_06 | AC | 477 ms
22,636 KB |
testcase_07 | TLE | - |
testcase_08 | -- | - |
testcase_09 | -- | - |
testcase_10 | -- | - |
testcase_11 | -- | - |
testcase_12 | -- | - |
testcase_13 | -- | - |
ソースコード
N = int(input()) S = [] candi = set() for _ in range(N): s=input() candi.add(s) s = ["n","b","m","g","r",""] b = ["i","a","a","e","u","u"] #print(candi) s5=[] b6=[] for i in range(6): if i<5: s5.append(i) b6.append(i) import itertools ss = list(itertools.permutations(s,6)) bb = list(itertools.permutations(b,6)) #print(ss) flag=False for i in ss: for j in bb: ca = [] for k in range(len(i)): ca.append(i[k]+j[k]) ccc = list(itertools.permutations(ca,6)) for cccc in ccc: candidate = "".join(cccc) if candidate not in candi: print(candidate) exit() print("No")