Skip to content

Commit efb037f

Browse files
authored
Revert changes to not include upper limit (#2261)
The docs diverged from the current state of the tests by including the upper limit
1 parent 3f7284e commit efb037f

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

exercises/sum-of-multiples/instructions.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ The points awarded depend on two things:
99

1010
The energy points are awarded according to the following rules:
1111

12-
1. For each magical item, take the base value and find all the multiples of that value that are less than or equal to the level number.
12+
1. For each magical item, take the base value and find all the multiples of that value that are less than the level number.
1313
2. Combine the sets of numbers.
1414
3. Remove any duplicates.
1515
4. Calculate the sum of all the numbers that are left.
@@ -18,10 +18,10 @@ Let's look at an example:
1818

1919
**The player completed level 20 and found two magical items with base values of 3 and 5.**
2020

21-
To calculate the energy points earned by the player, we need to find all the unique multiples of these base values that are less than or equal to level 20.
21+
To calculate the energy points earned by the player, we need to find all the unique multiples of these base values that are less than level 20.
2222

23-
- Multiples of 3 up to 20: `{3, 6, 9, 12, 15, 18}`
24-
- Multiples of 5 up to 20: `{5, 10, 15, 20}`
25-
- Combine the sets and remove duplicates: `{3, 5, 6, 9, 10, 12, 15, 18, 20}`
26-
- Sum the unique multiples: `3 + 5 + 6 + 9 + 10 + 12 + 15 + 18 + 20 = 98`
27-
- Therefore, the player earns **98** energy points for completing level 20 and finding the two magical items with base values of 3 and 5.
23+
- Multiples of 3 less than 20: `{3, 6, 9, 12, 15, 18}`
24+
- Multiples of 5 less than 20: `{5, 10, 15}`
25+
- Combine the sets and remove duplicates: `{3, 5, 6, 9, 10, 12, 15, 18}`
26+
- Sum the unique multiples: `3 + 5 + 6 + 9 + 10 + 12 + 15 + 18 = 78`
27+
- Therefore, the player earns **78** energy points for completing level 20 and finding the two magical items with base values of 3 and 5.

0 commit comments

Comments
 (0)