結果
| 問題 | No.1701 half price |
| コンテスト | |
| ユーザー |
sasa8uyauya
|
| 提出日時 | 2024-08-08 19:50:27 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 208 bytes |
| 記録 | |
| コンパイル時間 | 498 ms |
| コンパイル使用メモリ | 95,856 KB |
| 実行使用メモリ | 84,992 KB |
| 最終ジャッジ日時 | 2026-08-24 21:50:43 |
| 合計ジャッジ時間 | 3,921 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 2 |
| other | AC * 11 WA * 9 |
ソースコード
n,w=map(int,input().split()) a=list(map(int,input().split())) c=0 for i in range(1,1<<n): b=[a[j] for j in range(n) if (i>>j)&1] if sum(b)==w: c+=1 elif sum(b)>w: if (w-sum(b))*2 in b: c+=1 print(c)
sasa8uyauya