So this is bigger than just this question, After my If(n % 400 == 0 && n % 100 == 0 || n % 4 == 0) { I get an error that always says "Error in com/codegym/task/task04/task0414/Solution.java on line 18 ';' expected" but I don't think it belongs there, I can figure the rest out on my, I just gotta know after all my "If(such and such)" why I'm getting this. Ill try other people's code and it'll work, Im not sure why mine doesn't. Thanks for the support!
package com.codegym.task.task04.task0414;
/*
Number of days in the year
*/
import java.io.*;
import java.util.Scanner;
public class Solution {
public static void main(String[] args) throws Exception {
//write your code here
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
Scanner scanner = new Scanner(system.in);
int year = scanner.nextInt;
If(n % 400 == 0 && n % 100 ==0 || n % 4 == 0){
System.out.println ("Number of days in the year: 366");
}else
System.out.println("Number of days in the year: 365")
}
}