結果
問題 | No.2715 Unique Chimatagram |
ユーザー | june19312 |
提出日時 | 2024-04-05 21:36:25 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 810 bytes |
コンパイル時間 | 328 ms |
コンパイル使用メモリ | 82,232 KB |
実行使用メモリ | 81,416 KB |
最終ジャッジ日時 | 2024-10-01 01:49:59 |
合計ジャッジ時間 | 5,528 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 36 ms
52,572 KB |
testcase_01 | AC | 36 ms
53,436 KB |
testcase_02 | AC | 38 ms
53,016 KB |
testcase_03 | AC | 37 ms
52,252 KB |
testcase_04 | AC | 36 ms
52,612 KB |
testcase_05 | AC | 39 ms
53,812 KB |
testcase_06 | AC | 36 ms
52,568 KB |
testcase_07 | AC | 39 ms
52,400 KB |
testcase_08 | AC | 76 ms
79,580 KB |
testcase_09 | AC | 78 ms
79,940 KB |
testcase_10 | AC | 78 ms
79,372 KB |
testcase_11 | AC | 79 ms
80,104 KB |
testcase_12 | AC | 78 ms
79,604 KB |
testcase_13 | AC | 78 ms
79,624 KB |
testcase_14 | AC | 80 ms
79,532 KB |
testcase_15 | AC | 81 ms
79,548 KB |
testcase_16 | AC | 76 ms
79,736 KB |
testcase_17 | AC | 78 ms
79,192 KB |
testcase_18 | AC | 79 ms
80,860 KB |
testcase_19 | AC | 77 ms
81,168 KB |
testcase_20 | AC | 80 ms
80,756 KB |
testcase_21 | AC | 82 ms
80,928 KB |
testcase_22 | AC | 79 ms
80,700 KB |
testcase_23 | AC | 76 ms
81,004 KB |
testcase_24 | AC | 78 ms
81,204 KB |
testcase_25 | AC | 80 ms
80,888 KB |
testcase_26 | AC | 80 ms
81,416 KB |
testcase_27 | AC | 84 ms
81,212 KB |
testcase_28 | WA | - |
testcase_29 | WA | - |
testcase_30 | WA | - |
testcase_31 | WA | - |
testcase_32 | WA | - |
testcase_33 | AC | 38 ms
52,188 KB |
testcase_34 | AC | 36 ms
52,692 KB |
testcase_35 | AC | 37 ms
53,224 KB |
testcase_36 | WA | - |
testcase_37 | WA | - |
testcase_38 | WA | - |
testcase_39 | WA | - |
testcase_40 | WA | - |
testcase_41 | AC | 72 ms
78,620 KB |
testcase_42 | AC | 51 ms
62,016 KB |
ソースコード
N = int(input()) dic = {} dic2 = {} abc = ["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"] for i in range(N): S = list(input()) S.sort() nex = "".join(S) if nex in dic: dic[nex] += 1 else: dic[nex] = 1 for j in abc: nex2 = S + [j] nex2.sort() nex3 = "".join(nex2) if nex3 not in dic2: dic2[nex3] = 1 else: dic2[nex3] += 1 #print(dic) #print(dic2) for ind,val in dic.items(): if val == 1: for j in abc: nex2 = S + [j] nex2.sort() nex3 = "".join(nex2) if nex3 in dic2 and dic2[nex3] == 1: print(nex3) exit() print(-1)