結果

問題 No.1205 Eye Drops
ユーザー rymg111rymg111
提出日時 2020-09-21 18:14:29
言語 Java21
(openjdk 21)
結果
RE  
実行時間 -
コード長 551 bytes
コンパイル時間 1,990 ms
コンパイル使用メモリ 71,920 KB
実行使用メモリ 60,640 KB
最終ジャッジ日時 2023-09-06 17:24:18
合計ジャッジ時間 9,551 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 125 ms
55,624 KB
testcase_01 AC 124 ms
55,688 KB
testcase_02 AC 185 ms
56,208 KB
testcase_03 AC 128 ms
56,168 KB
testcase_04 AC 137 ms
57,712 KB
testcase_05 AC 155 ms
55,964 KB
testcase_06 AC 158 ms
56,060 KB
testcase_07 AC 124 ms
55,608 KB
testcase_08 AC 133 ms
53,372 KB
testcase_09 AC 142 ms
55,668 KB
testcase_10 AC 155 ms
56,128 KB
testcase_11 AC 187 ms
56,212 KB
testcase_12 AC 135 ms
55,432 KB
testcase_13 AC 176 ms
55,876 KB
testcase_14 AC 183 ms
55,808 KB
testcase_15 AC 173 ms
55,892 KB
testcase_16 AC 153 ms
56,048 KB
testcase_17 AC 126 ms
55,732 KB
testcase_18 AC 152 ms
55,804 KB
testcase_19 AC 142 ms
55,408 KB
testcase_20 AC 184 ms
55,844 KB
testcase_21 AC 131 ms
55,580 KB
testcase_22 AC 178 ms
55,832 KB
testcase_23 AC 187 ms
56,308 KB
testcase_24 AC 135 ms
55,672 KB
testcase_25 AC 126 ms
55,632 KB
testcase_26 AC 147 ms
55,708 KB
testcase_27 AC 133 ms
55,580 KB
testcase_28 AC 177 ms
55,588 KB
testcase_29 AC 132 ms
56,136 KB
testcase_30 AC 141 ms
55,576 KB
testcase_31 AC 134 ms
55,820 KB
testcase_32 AC 122 ms
55,648 KB
testcase_33 AC 122 ms
55,636 KB
testcase_34 AC 123 ms
55,632 KB
testcase_35 AC 124 ms
56,056 KB
testcase_36 AC 124 ms
55,668 KB
testcase_37 RE -
testcase_38 AC 124 ms
55,772 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		sc.nextInt();
		int infoNum = sc.nextInt();
		int prevKey = 0;
		int prevValue = 0;
		int nextKey = 0;
		int nextValue = 0;
		for(int i = 0; i < infoNum; i++) {
			nextKey = sc.nextInt();
			nextValue = sc.nextInt();
			if(Math.abs(nextKey - prevKey) < Math.abs(nextValue - prevValue)) {
				System.out.println("No");
				return;
			}
			prevKey = nextKey;
			prevValue = nextValue;
		}
		System.out.println("Yes");
	}
}
0