diff --git a/exercises/comparing_improper_fractions_and_mixed_numbers.html b/exercises/comparing_improper_fractions_and_mixed_numbers.html index 5683c9282..303c6b9d5 100644 --- a/exercises/comparing_improper_fractions_and_mixed_numbers.html +++ b/exercises/comparing_improper_fractions_and_mixed_numbers.html @@ -1,5 +1,5 @@ - + Comparing improper fractions and mixed numbers @@ -10,7 +10,7 @@
-
+
randRange( 1, 5 ) WHOLE @@ -26,7 +26,7 @@ M_DENOM_2 / getGCD( M_NUM_2, M_DENOM_2 ) WHOLE_2 * M_REDUCED_DENOM + M_REDUCED_NUM - M_REDUCED_DENOM + M_REDUCED_DENOM getLCM( M_DENOM_REDUCED, I_DENOM ) LCM / M_DENOM_REDUCED @@ -62,21 +62,23 @@

First, let's convert the mixed number to an improper fraction with the same denominator.

-

To get the numerator of the improper fraction, multiply the denominator (M_DENOM_REDUCED) by the whole number (WHOLE) and add the numerator (M_NUM_REDUCED).

M_DENOM_REDUCED * WHOLE+M_NUM_REDUCED = M_AS_I

+

To get the numerator of the improper fraction, multiply the denominator (M_DENOM_REDUCED) by the whole number (WHOLE) and add the numerator (M_NUM_REDUCED).

M_DENOM_REDUCED \cdot WHOLE+M_NUM_REDUCED = M_AS_I

We can write the mixed number as an improper fraction with numerator M_AS_I and denominator M_DENOM_REDUCED.

Now we need to compare fraction ( M_AS_I, M_DENOM_REDUCED, false, true ) to fraction ( I_NUM, I_DENOM, false, true ).

-

It is easier to compare these two fractions when they have the same denominator.

-

Their smallest common denominator is the LCM of M_DENOM_REDUCED and I_DENOM.

-

\lcm(M_DENOM_REDUCED, I_DENOM) = LCM

-
-

The first fraction BECOMES_1 \dfrac{M_AS_I * F1}{LCM}.

-

The second fraction BECOMES_2 \dfrac{I_NUM * F2}{LCM}.

+
+

It is easier to compare these two fractions when they have the same denominator.

+

Their smallest common denominator is the LCM of M_DENOM_REDUCED and I_DENOM.

+

\lcm(M_DENOM_REDUCED, I_DENOM) = LCM

+
+

The first fraction BECOMES_1 \dfrac{M_AS_I * F1}{LCM}.

+

The second fraction BECOMES_2 \dfrac{I_NUM * F2}{LCM}.

+

We see that \dfrac{M_AS_I * F1}{LCM} SOLUTION \dfrac{I_NUM * F2}{LCM}.

-
+
randRange( 1, 5 ) randRange( 1, 5 ) @@ -128,15 +130,17 @@

First, let's convert the mixed number to an improper fraction with the same denominator.

-

To get the numerator of the improper fraction, multiply the denominator (M_DENOM_REDUCED) by the whole number (WHOLE) and add the numerator (M_NUM_REDUCED).

M_DENOM_REDUCED*WHOLE+M_NUM_REDUCED = M_AS_I

+

To get the numerator of the improper fraction, multiply the denominator (M_DENOM_REDUCED) by the whole number (WHOLE) and add the numerator (M_NUM_REDUCED).

M_DENOM_REDUCED\cdotWHOLE+M_NUM_REDUCED = M_AS_I

We can write the mixed number as an improper fraction with numerator M_AS_I and denominator M_DENOM_REDUCED.

Now we need to compare fraction ( M_AS_I, M_DENOM_REDUCED, false, true ) to fraction ( I_NUM, I_DENOM, false, true )

-

It is easier to compare these two fractions when they have the same denominator.

-

Their smallest common denominator is the LCM of M_DENOM_REDUCED and I_DENOM.

-

\lcm(M_DENOM_REDUCED, I_DENOM) = LCM

-
-

The first fraction BECOMES_1 \dfrac{M_AS_I * F1}{LCM}.

-

The second fraction BECOMES_2 \dfrac{I_NUM * F2}{LCM}.

+
+

It is easier to compare these two fractions when they have the same denominator.

+

Their smallest common denominator is the LCM of M_DENOM_REDUCED and I_DENOM.

+

\lcm(M_DENOM_REDUCED, I_DENOM) = LCM

+
+

The first fraction BECOMES_1 \dfrac{M_AS_I * F1}{LCM}.

+

The second fraction BECOMES_2 \dfrac{I_NUM * F2}{LCM}.

+

We see that \dfrac{M_AS_I * F1}{LCM} SOLUTION \dfrac{I_NUM * F2}{LCM}.