結果

問題 No.2015 Stair Counter
ユーザー 👑 tatt61880tatt61880
提出日時 2023-03-12 18:58:52
言語 Kuin
(KuinC++ v.2021.9.17)
結果
AC  
実行時間 84 ms / 2,000 ms
コード長 384 bytes
コンパイル時間 3,692 ms
コンパイル使用メモリ 145,764 KB
実行使用メモリ 5,336 KB
最終ジャッジ日時 2023-10-18 10:44:17
合計ジャッジ時間 7,857 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,348 KB
testcase_01 AC 47 ms
4,348 KB
testcase_02 AC 48 ms
4,348 KB
testcase_03 AC 51 ms
4,348 KB
testcase_04 AC 44 ms
4,348 KB
testcase_05 AC 43 ms
4,348 KB
testcase_06 AC 54 ms
4,348 KB
testcase_07 AC 54 ms
4,348 KB
testcase_08 AC 54 ms
4,348 KB
testcase_09 AC 39 ms
4,348 KB
testcase_10 AC 41 ms
4,348 KB
testcase_11 AC 45 ms
4,348 KB
testcase_12 AC 39 ms
4,372 KB
testcase_13 AC 41 ms
4,416 KB
testcase_14 AC 45 ms
4,408 KB
testcase_15 AC 50 ms
4,808 KB
testcase_16 AC 78 ms
5,072 KB
testcase_17 AC 46 ms
5,072 KB
testcase_18 AC 68 ms
5,072 KB
testcase_19 AC 84 ms
5,336 KB
testcase_20 AC 58 ms
5,336 KB
testcase_21 AC 45 ms
4,348 KB
testcase_22 AC 48 ms
4,348 KB
testcase_23 AC 52 ms
4,348 KB
testcase_24 AC 45 ms
4,348 KB
testcase_25 AC 46 ms
4,348 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

func main()
	var t: int :: cui@inputInt()
	for(1, t)
		var n: int :: cui@inputInt()
		var m: int :: cui@inputInt()
		var a: []int :: #[n]int
		for i(0, n - 1)
			do a[i] :: cui@inputInt()
		end for
		
		var ans: bool :: true
		for i(0, n - 2)
			if(a[i] + a[i + 1] < m)
				do ans :: false
				break i
			end if
		end for
		do cui@print((ans ?("Yes", "No")) ~ "\n")
	end for
end func
0