結果

問題 No.9010 うるう年判定
ユーザー ウップス600
提出日時 2022-01-04 20:56:45
言語 Java
(openjdk 23)
結果
AC  
実行時間 122 ms / 2,000 ms
コード長 358 bytes
コンパイル時間 2,014 ms
コンパイル使用メモリ 73,520 KB
実行使用メモリ 41,284 KB
最終ジャッジ日時 2024-10-14 17:02:50
合計ジャッジ時間 6,303 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 25
権限があれば一括ダウンロードができます

ソースコード

diff #

import java. util. Scanner;

public class Main{
	public static void main (String[] args){
		Scanner scanner = new Scanner (System. in);
		int year = scanner. nextInt();
		
		if (year % 100 == 0 && year % 400 != 0){
			System. out. println ("No");
		}else if (year % 4 == 0){
			System. out. println ("Yes");
		}else{
			System. out. println ("No");
		}
	}
}
0