Oliver Eyton-Williams ee1e8abd87
feat(curriculum): restore seed + solution to Chinese (#40683)
* feat(tools): add seed/solution restore script

* chore(curriculum): remove empty sections' markers

* chore(curriculum): add seed + solution to Chinese

* chore: remove old formatter

* fix: update getChallenges

parse translated challenges separately, without reference to the source

* chore(curriculum): add dashedName to English

* chore(curriculum): add dashedName to Chinese

* refactor: remove unused challenge property 'name'

* fix: relax dashedName requirement

* fix: stray tag

Remove stray `pre` tag from challenge file.

Signed-off-by: nhcarrigan <nhcarrigan@gmail.com>

Co-authored-by: nhcarrigan <nhcarrigan@gmail.com>
2021-01-12 19:31:00 -07:00

63 lines
1.3 KiB
Markdown

---
id: bd7123c9c441eddfaeb5bdef
title: Understanding Boolean Values
challengeType: 1
videoUrl: 'https://scrimba.com/c/c9Me8t4'
forumTopicId: 301176
dashedName: understanding-boolean-values
---
# --description--
Another data type is the <dfn>Boolean</dfn>. `Booleans` may only be one of two values: `true` or `false`. They are basically little on-off switches, where `true` is "on" and `false` is "off." These two states are mutually exclusive.
**Note**
`Boolean` values are never written with quotes. The `strings` `"true"` and `"false"` are not `Boolean` and have no special meaning in JavaScript.
# --instructions--
Modify the `welcomeToBooleans` function so that it returns `true` instead of `false` when the run button is clicked.
# --hints--
The `welcomeToBooleans()` function should return a boolean (true/false) value.
```js
assert(typeof welcomeToBooleans() === 'boolean');
```
`welcomeToBooleans()` should return true.
```js
assert(welcomeToBooleans() === true);
```
# --seed--
## --after-user-code--
```js
welcomeToBooleans();
```
## --seed-contents--
```js
function welcomeToBooleans() {
// Only change code below this line
return false; // Change this line
// Only change code above this line
}
```
# --solutions--
```js
function welcomeToBooleans() {
return true; // Change this line
}
```