Skip to content

Commit

Permalink
Fix spellbound steel instructions (#693)
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanplusplus authored Sep 9, 2024
1 parent 03238c1 commit f6b78fd
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions exercises/concept/spellbound-steel/.docs/instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,14 @@ SpellboundSteel.capitalize_cards(cards)
In the game is it important to calculate the power level of all cards.
The power for all cards can been seen in the following table:

| Card Type | Power Level |
| --------- | ----------- |
| Warrior | 10 |
| Mage | 20 |
| Rogue | 30 |
| Fireball | 15 |
| Ice Storm | 25 |
| Lightning Bolt | 35 |
| Card Type | Power Level |
|----------------|-------------|
| Warrior | 10 |
| Mage | 20 |
| Rogue | 30 |
| Fireball | 15 |
| Ice Storm | 25 |
| Lightning Bolt | 35 |

Implement a method `SpellboundSteel.calculate_power_level` that takes an `Array` of `String` cards and returns the total power level of all cards.

Expand All @@ -60,12 +60,12 @@ SpellboundSteel.calculate_power_level(cards)

In the game, there are what is known as cursed cards.
These cards is a hidden card that can only be decoded by the player who played it.
To decode the card you need to take every second character in the card name and reverse it.
To decode the card you need to take every second character in the card name and remove it.
That will give the name of the card.

Implement a method `SpellboundSteel.decode_card` that takes a `String` card and returns the decoded card.

```crystal
SpellboundSteel.decode_card("Wraoir")
SpellboundSteel.decode_card("Wbalrrrlimoqr")
# => "Warrior"
```

0 comments on commit f6b78fd

Please sign in to comment.