結果

問題 No.138 化石のバージョン
ユーザー r.suzukir.suzuki
提出日時 2015-12-30 15:23:17
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 574 bytes
コンパイル時間 5,788 ms
コンパイル使用メモリ 74,500 KB
実行使用メモリ 57,940 KB
最終ジャッジ日時 2023-10-19 12:40:03
合計ジャッジ時間 11,725 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 134 ms
57,732 KB
testcase_01 AC 135 ms
57,240 KB
testcase_02 AC 134 ms
57,496 KB
testcase_03 AC 136 ms
57,440 KB
testcase_04 AC 134 ms
57,228 KB
testcase_05 AC 138 ms
57,748 KB
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 AC 133 ms
57,516 KB
testcase_17 AC 131 ms
57,572 KB
testcase_18 AC 131 ms
57,392 KB
testcase_19 AC 128 ms
57,200 KB
testcase_20 AC 134 ms
57,444 KB
testcase_21 AC 132 ms
57,544 KB
testcase_22 AC 129 ms
55,608 KB
testcase_23 AC 130 ms
57,484 KB
testcase_24 AC 130 ms
57,480 KB
testcase_25 AC 131 ms
57,500 KB
testcase_26 WA -
testcase_27 AC 130 ms
57,184 KB
testcase_28 AC 135 ms
57,740 KB
testcase_29 AC 133 ms
57,256 KB
testcase_30 AC 131 ms
55,508 KB
testcase_31 AC 131 ms
57,516 KB
testcase_32 AC 130 ms
57,484 KB
testcase_33 WA -
testcase_34 WA -
testcase_35 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

class Version {
	int[] num = new int[3];

}

public class No_138 {

	public static void main(String[] args) {
		java.util.Scanner sc = new java.util.Scanner(System.in);
		String[] s1 = sc.nextLine().split("\\.");
		String[] s2 = sc.nextLine().split("\\.");
		String ans = "YES";

		Version old = new Version();
		Version set = new Version();

		for (int i = 0; i < 3; i++) {
			old.num[i] = Integer.parseInt(s1[i]);
			set.num[i] = Integer.parseInt(s2[i]);
			if (old.num[i] < set.num[i]) {
				ans = "NO";
				break;
			}
		}
		System.out.println(ans);
		sc.close();

	}

}
0