diff --git a/.DS_Store b/.DS_Store index 48918f5..f9ed7d3 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/.idea/workspace.xml b/.idea/workspace.xml index fcfa337..cc85b9c 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -58,18 +58,18 @@ - - + + - - - - - - - - + + + + + + + + @@ -537,18 +537,18 @@ - - + + - - - - - - - - + + + + + + + + diff --git a/src/Fraction.java b/src/Fraction.java index 6233ae4..e58465f 100644 --- a/src/Fraction.java +++ b/src/Fraction.java @@ -12,10 +12,10 @@ public class Fraction { /** * Public constructor - * + * * @param w The whole part of this fraction * @param n The numerator of this fraction - * @param d The denominator + * @param d The denominator of this fraction */ public Fraction(int w, int n, int d) { @@ -24,18 +24,34 @@ public Fraction(int w, int n, int d) { setdenominator(d); } + /** + * + * @return an int representing the whole part of this fraction + */ public int getWhole() { return whole; } + /** + * + * @return an int representing the numerator of this fraction + */ public int getNumerator() { return numerator; } + /** + * + * @return an int representing the denominator of this fraction + */ public int getdenominator() { return denominator; } + /** + * + * @param d the new value of the denominator + */ public void setdenominator(int d) { if (d != 0) {