結果
問題 | No.587 七対子 |
ユーザー |
|
提出日時 | 2017-11-03 22:52:45 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
WA
|
実行時間 | - |
コード長 | 298 bytes |
コンパイル時間 | 96 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 10,752 KB |
最終ジャッジ日時 | 2024-11-22 16:14:04 |
合計ジャッジ時間 | 2,116 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 26 WA * 9 |
ソースコード
from itertools import groupby s = input() se = set(s) freq = [len(list(group)) for key, group in groupby(s)] f = {len(list(group)):key for key, group in groupby(s)} num2 = len(list(filter(lambda x :x==2,freq))) if num2==6 and len(se)==7 and len(s)==13: print(f[1]) else: print("Impossible")