Commit 819394aa authored by jinny.wilkin's avatar jinny.wilkin

Added comments

parent 6b7cad1f
No preview for this file type
......@@ -3,7 +3,7 @@ public class App {
/* Week 2 Exercises
14/02 Jinny Wilkin */
int fingersOnRightHand = 5; // Ex 4.1
//int fingersOnRightHand = 5; // Ex 4.1
countDays(); // Ex 8.1
......@@ -145,7 +145,7 @@ public class App {
monthDo++;
}while(monthDo < 14);
System.out.println("There are " + daysBetween(26, 8, 1996, 14, 2, 2022));
System.out.println("There have been " + daysBetween(26, 8, 1996, 14, 2, 2022)+ " days between the day I was born and the day I wrote this");
}
......@@ -186,7 +186,7 @@ public class App {
}
public static boolean isItALeapYear(int year){
public static boolean isItALeapYear(int year){ // Ex9
if(year % 4 == 0){
return(true);
}else{
......@@ -194,6 +194,8 @@ public class App {
}
}
// Ex 10
public static int daysInYear(int year){
if(isItALeapYear(year)){
return(366);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment