結果

問題 No.2015 Stair Counter
ユーザー とりゐとりゐ
提出日時 2022-08-08 15:15:48
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 119 ms / 2,000 ms
コード長 269 bytes
コンパイル時間 224 ms
コンパイル使用メモリ 81,464 KB
実行使用メモリ 102,792 KB
最終ジャッジ日時 2023-10-19 04:56:50
合計ジャッジ時間 4,788 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 40 ms
53,328 KB
testcase_01 AC 119 ms
75,776 KB
testcase_02 AC 108 ms
75,976 KB
testcase_03 AC 106 ms
75,996 KB
testcase_04 AC 88 ms
75,752 KB
testcase_05 AC 85 ms
75,932 KB
testcase_06 AC 109 ms
76,032 KB
testcase_07 AC 109 ms
76,244 KB
testcase_08 AC 106 ms
76,008 KB
testcase_09 AC 58 ms
74,836 KB
testcase_10 AC 59 ms
74,868 KB
testcase_11 AC 60 ms
74,840 KB
testcase_12 AC 59 ms
75,700 KB
testcase_13 AC 60 ms
76,256 KB
testcase_14 AC 60 ms
75,948 KB
testcase_15 AC 68 ms
85,788 KB
testcase_16 AC 83 ms
99,516 KB
testcase_17 AC 69 ms
89,412 KB
testcase_18 AC 73 ms
91,428 KB
testcase_19 AC 86 ms
102,792 KB
testcase_20 AC 75 ms
95,824 KB
testcase_21 AC 89 ms
75,748 KB
testcase_22 AC 102 ms
75,844 KB
testcase_23 AC 108 ms
76,060 KB
testcase_24 AC 93 ms
75,772 KB
testcase_25 AC 90 ms
75,752 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from sys import stdin
input=lambda :stdin.readline()[:-1]

def solve():
  n,m=map(int,input().split())
  a=list(map(int,input().split()))
  for i in range(n-1):
    if a[i]+a[i+1]<m:
      print('No')
      return
  print('Yes')

for _ in range(int(input())):
  solve()
0