結果
| 問題 |
No.393 2本の竹
|
| コンテスト | |
| ユーザー |
hiyokko2
|
| 提出日時 | 2016-07-30 18:17:24 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 420 bytes |
| コンパイル時間 | 210 ms |
| コンパイル使用メモリ | 12,672 KB |
| 実行使用メモリ | 30,768 KB |
| 最終ジャッジ日時 | 2024-11-06 21:21:27 |
| 合計ジャッジ時間 | 3,555 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | WA * 9 TLE * 1 -- * 18 |
ソースコード
d = int(input())
for _ in range(d):
n1, n2 = map(int, input().split())
input()
A = sorted(map(int, input().split()))
ans = 0
syugo = {(n1, n2)}
for a in A:
print("a = {}".format(a))
if syugo == set():
break
new_syugo = set()
for x, y in syugo:
if x - a >= 0:
new_syugo.add((x - a, y))
if y - a >= 0:
new_syugo.add((x, y - a))
syugo = new_syugo
print(syugo)
ans += 1
print(ans - 1)
hiyokko2