結果

問題 No.1570 Blocks
ユーザー NatsubiSoganNatsubiSogan
提出日時 2021-06-27 13:21:43
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 200 bytes
コンパイル時間 536 ms
コンパイル使用メモリ 10,672 KB
実行使用メモリ 28,188 KB
最終ジャッジ日時 2023-09-07 17:34:19
合計ジャッジ時間 14,651 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 17 ms
7,820 KB
testcase_01 AC 16 ms
8,256 KB
testcase_02 AC 274 ms
21,472 KB
testcase_03 WA -
testcase_04 AC 253 ms
19,688 KB
testcase_05 AC 252 ms
20,396 KB
testcase_06 WA -
testcase_07 AC 45 ms
10,004 KB
testcase_08 WA -
testcase_09 WA -
testcase_10 AC 312 ms
23,152 KB
testcase_11 AC 345 ms
24,676 KB
testcase_12 WA -
testcase_13 AC 430 ms
27,252 KB
testcase_14 AC 427 ms
27,636 KB
testcase_15 AC 180 ms
17,036 KB
testcase_16 AC 426 ms
27,516 KB
testcase_17 WA -
testcase_18 AC 340 ms
23,940 KB
testcase_19 WA -
testcase_20 AC 184 ms
16,796 KB
testcase_21 WA -
testcase_22 AC 15 ms
8,080 KB
testcase_23 AC 15 ms
7,876 KB
testcase_24 AC 15 ms
8,256 KB
testcase_25 AC 16 ms
8,216 KB
testcase_26 AC 15 ms
8,116 KB
testcase_27 AC 16 ms
7,868 KB
testcase_28 AC 15 ms
8,096 KB
testcase_29 AC 15 ms
8,088 KB
testcase_30 AC 16 ms
7,876 KB
testcase_31 AC 16 ms
8,156 KB
testcase_32 AC 396 ms
27,156 KB
testcase_33 WA -
testcase_34 AC 379 ms
26,228 KB
testcase_35 WA -
testcase_36 AC 401 ms
26,852 KB
testcase_37 WA -
testcase_38 WA -
testcase_39 AC 422 ms
27,568 KB
testcase_40 AC 390 ms
26,980 KB
testcase_41 WA -
testcase_42 AC 436 ms
28,188 KB
testcase_43 AC 436 ms
28,144 KB
testcase_44 AC 430 ms
28,148 KB
testcase_45 AC 434 ms
28,148 KB
testcase_46 AC 446 ms
28,040 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
ab = [list(map(int, input().split())) for i in range(n)]
ab.sort()
s = 0
for i in range(n):
    if s > ab[i][1]:
        exit(print("No"))
    else:
        s += ab[i][0]
print("Yes")
0