You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
public class Fraction extends Number implements Comparable<Fraction> {
793
+
public class Fraction extends Number implements Comparable<Fraction> { // fraction class is a child of Number and implements the Comparable interface
794
794
...
795
795
}
796
796
</code>
@@ -804,7 +804,7 @@ public class Fraction extends Number implements Comparable<Fraction> {
804
804
805
805
<programxml:id="java-comparable2"language="java">
806
806
<code>
807
-
public int compareTo(Fraction other) {
807
+
public int compareTo(Fraction other) { // compare this fraction with another fraction
0 commit comments