結果
問題 |
No.9010 うるう年判定
|
ユーザー |
|
提出日時 | 2018-06-10 22:15:38 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 136 ms / 2,000 ms |
コード長 | 591 bytes |
コンパイル時間 | 3,618 ms |
コンパイル使用メモリ | 74,724 KB |
実行使用メモリ | 54,408 KB |
最終ジャッジ日時 | 2024-06-22 01:14:20 |
合計ジャッジ時間 | 8,171 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 25 |
ソースコード
import java.util.Scanner; public class Test { public static void main (String[] args) { Scanner sc = new Scanner(System.in); int year = sc.nextInt(); if (year % 4 == 0) { if (year % 100 == 0) { if (year % 400 == 0) { System.out.println("Yes"); } else { System.out.println("No"); } } else { System.out.println("Yes"); } } else { System.out.println("No"); } } }