Skip to content

Commit

Permalink
some syntax and layout
Browse files Browse the repository at this point in the history
  • Loading branch information
fine-code committed Oct 16, 2020
1 parent 672836e commit f3ba5bd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions MagicDates.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ public class MagicDates extends GaddisChallenges {
private int userYear;

private int[] numDaysInMonth = [31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];

public void start() {
print("Ready for some magic? Let's see if you can guess a Magic Date! ");

Expand All @@ -25,7 +26,7 @@ public void start() {
else {
print("That day is invalid");
}

print("Enter a two-digit year: (Example: 08 for 2008");
tempYear = scan.nextInt();
if (tempYear.toString().length() == 2) {
Expand All @@ -39,7 +40,7 @@ public void start() {

}

private calculateMagic() {
private void calculateMagic() {
return (userMonth * userDay == userYear);
}
}
4 changes: 2 additions & 2 deletions RomanNumeralConverter.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ public class RomanNumeralConverter extends GaddisChallenges {

private int userNumber;
private String[] romanNumerals = ["I", "II", "III", "IV", "V",
"VI", "VII", "VIII", "IX", "X"];
"VI", "VII", "VIII", "IX", "X"];

private void start() {
print("Enter a number within the range of 1 through 10");
userNumber = scan.nextInt();
Expand Down

0 comments on commit f3ba5bd

Please sign in to comment.