diff --git a/exercises/converting_decimals_to_fractions_1.html b/exercises/converting_decimals_to_fractions_1.html index 477b0f48a..6475718b5 100644 --- a/exercises/converting_decimals_to_fractions_1.html +++ b/exercises/converting_decimals_to_fractions_1.html @@ -1,5 +1,5 @@ - + Converting decimals to fractions 1 @@ -13,11 +13,17 @@ randRange( 1, 9 ) / 10 floor( D * 10 ) -

Express localeToFixed(D, 1 ) as a fraction.

-

D

+

Express localeToFixed(D, 1) as a fraction.

+

D

-

The number T is in the tenths place, so we have cardinalThrough20( T ) tenths.

-

CardinalThrough20( T ) tenths can be written as fraction( T, 10 ).

+

+ The number T is in the tenths place, + so we have cardinalThrough20(T) plural_form(decimalPlaceNames[1], T). +

+

+ CardinalThrough20(T) plural_form(decimalPlaceNames[1], T) + can be written as fraction(T, 10). +

@@ -28,12 +34,15 @@ round( D * 100 ) % 10

Express localeToFixed(D, 2 ) as a fraction.

-

D

-
-

The number T is in the tenths place, so we have cardinalThrough20( T ) tenths.

-

CardinalThrough20( T ) tenths can be written as fraction( T, 10 ).

-

The number H is in the hundredths place, so we have cardinalThrough20( H ) hundredths.

-

CardinalThrough20( H ) hundredths can be written as fraction( H, 100 ).

+

D

+
+

+ The number H is in the hundredths place, + so we have cardinalThrough20(H) plural_form(decimalPlaceNames[2], H).

+

+ CardinalThrough20(H) plural_form(decimalPlaceNames[2], H) + can be written as fraction(H, 100). +

Add the two parts together.

fraction( T, 10 ) + fraction( H, 100 )

diff --git a/exercises/converting_decimals_to_fractions_2.html b/exercises/converting_decimals_to_fractions_2.html index 0a32a4425..e81dfea47 100644 --- a/exercises/converting_decimals_to_fractions_2.html +++ b/exercises/converting_decimals_to_fractions_2.html @@ -15,7 +15,7 @@ NUMERATOR / 10000

Express localeToFixed(D, 4) as a fraction.

-

D

+

D

localeToFixed(D, 4) can be represented as follows.