Advertisement
john2054

LeapYear

Oct 7th, 2016
91
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.50 KB | None | 0 0
  1. import java.util.Scanner;
  2.  
  3. public class LeapYear {
  4.     public static void main(String[] args);
  5.      
  6.        Scanner isLeapYear = new Scanner(System.in);
  7.         System.out.print("Please type in the year: ");
  8.         int isLeapYear = scanner.next();
  9.         If isLeapYear/4==int && {isLeapYear/4 /100 /400 ==int} LeapYear=true;
  10.        
  11.         // i should create a print method including the correct code here
  12.        
  13.         else LeapYear=false
  14. // again the else code needs to come in here...
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement