結果

問題 No.9010 うるう年判定
ユーザー juugayajuugaya
提出日時 2020-06-12 21:24:30
言語 Java21
(openjdk 21)
結果
AC  
実行時間 117 ms / 2,000 ms
コード長 368 bytes
コンパイル時間 1,906 ms
コンパイル使用メモリ 71,340 KB
実行使用メモリ 56,768 KB
最終ジャッジ日時 2023-09-04 01:22:24
合計ジャッジ時間 6,481 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 115 ms
56,024 KB
testcase_01 AC 116 ms
55,876 KB
testcase_02 AC 114 ms
56,424 KB
testcase_03 AC 117 ms
56,076 KB
testcase_04 AC 116 ms
56,000 KB
testcase_05 AC 115 ms
56,000 KB
testcase_06 AC 115 ms
56,148 KB
testcase_07 AC 114 ms
56,228 KB
testcase_08 AC 115 ms
56,004 KB
testcase_09 AC 115 ms
56,448 KB
testcase_10 AC 115 ms
56,504 KB
testcase_11 AC 115 ms
56,676 KB
testcase_12 AC 115 ms
56,436 KB
testcase_13 AC 114 ms
55,552 KB
testcase_14 AC 114 ms
56,268 KB
testcase_15 AC 115 ms
56,660 KB
testcase_16 AC 115 ms
55,988 KB
testcase_17 AC 117 ms
55,828 KB
testcase_18 AC 117 ms
55,828 KB
testcase_19 AC 114 ms
56,768 KB
testcase_20 AC 114 ms
55,984 KB
testcase_21 AC 115 ms
56,460 KB
testcase_22 AC 114 ms
56,072 KB
testcase_23 AC 115 ms
56,216 KB
testcase_24 AC 117 ms
54,752 KB
testcase_25 AC 116 ms
56,508 KB
testcase_26 AC 116 ms
56,604 KB
testcase_27 AC 117 ms
56,284 KB
testcase_28 AC 116 ms
56,052 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

class Sample {

public static void main(String args[]) {

Scanner scanner = new Scanner(System.in);

String input = scanner.nextLine();

   int n =Integer.parseInt(input);
if(n%400==0){System.out.println("Yes");}
else if(n%100==0){System.out.println("No");}
else if(n%4==0){System.out.println("Yes");}
else{System.out.println("No");}



}

}
0