fix(curriculum): typos in making RPG game project at new JS (#47909)

fix(curriculum,learn): Fix a few misspellings
This commit is contained in:
Rafael Fontenelle
2022-10-07 15:15:48 -03:00
committed by GitHub
parent d2d08b4875
commit 0e42b79b69
3 changed files with 3 additions and 3 deletions

View File

@@ -7,7 +7,7 @@ dashedName: step-122
# --description--
JavaScript offers the built in `Math` utility which offers a number of mathematical tools. One of those is `Math.random()`, which generates a random number between 0 and 1. Another is `Math.floor()`, which rounds a given number down to the nearest integer.
JavaScript offers the built-in `Math` utility which offers a number of mathematical tools. One of those is `Math.random()`, which generates a random number between 0 and 1. Another is `Math.floor()`, which rounds a given number down to the nearest integer.
Using these, you can generate a random number within a range. For example, this generates a random number between 1 and 5: `Math.floor(Math.random() * 5) + 1;`.

View File

@@ -23,7 +23,7 @@ You should set `healthText.innerText` to `health`.
assert.match(attack.toString(), /healthText\.innerText\s*=\s*health/);
```
Ypu should update `monsterHealthText.innerText`.
You should update `monsterHealthText.innerText`.
```js
assert.match(attack.toString(), /monsterHealthText\.innerText/);

View File

@@ -33,7 +33,7 @@ Your `else if` statement should check if `monsterHealth` is less than or equal t
assert.match(attack.toString(), /else\s*if\s*\(\s*monsterHealth\s*<=\s*0\s*\)/);
```
Your `else if` statment should call the `defeatMonster` function.
Your `else if` statement should call the `defeatMonster` function.
```js
assert.match(attack.toString(), /else\s*if\s*\(\s*monsterHealth\s*<=\s*0\s*\)\s*\{\s*defeatMonster/);