結果
問題 | No.548 国士無双 |
ユーザー |
|
提出日時 | 2022-05-04 20:09:42 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 39 ms / 2,000 ms |
コード長 | 422 bytes |
コンパイル時間 | 171 ms |
コンパイル使用メモリ | 82,408 KB |
実行使用メモリ | 52,352 KB |
最終ジャッジ日時 | 2024-07-03 23:14:37 |
合計ジャッジ時間 | 1,952 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 24 |
ソースコード
#!/usr/bin/env python3 import sys def main(): S = input() l = [0] * 13 for ss in S: l[ord(ss) - ord("a")] += 1 # 0 2 1つ # 1 全て if l == [1] * 13: print(*"abcdefghijklm", sep="\n") return if sorted(l) == [0] + [1] * 11 + [2]: print(chr(l.index(0) + ord("a"))) return print("Impossible") return if __name__ == '__main__': main()