mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-04-05 07:01:05 -04:00
fix(curriculum): remove truthy and falsy script from lecture block (#57185)
This commit is contained in:
@@ -50,10 +50,6 @@
|
||||
"id": "673271fd11d063daf0cf8d20",
|
||||
"title": "What Are Conditional Statements, and How Do If/Else If/Else Statements Work?"
|
||||
},
|
||||
{
|
||||
"id": "67327205e292dbdb1ffa0c21",
|
||||
"title": "What Are Truthy and Falsy Values?"
|
||||
},
|
||||
{
|
||||
"id": "6732720e95f6a0db526a2e4d",
|
||||
"title": "What Are Binary Logical Operators, and How Do They Work?"
|
||||
|
||||
@@ -1,121 +0,0 @@
|
||||
---
|
||||
id: 67327205e292dbdb1ffa0c21
|
||||
title: What Are Truthy and Falsy Values?
|
||||
challengeType: 11
|
||||
videoId: nVAaxZ34khk
|
||||
dashedName: what-are-truthy-and-falsy-values
|
||||
---
|
||||
|
||||
# --description--
|
||||
|
||||
Watch the lecture video and answer the questions below.
|
||||
|
||||
# --questions--
|
||||
|
||||
## --text--
|
||||
|
||||
What controls how certain values behave in conditional statements in JavaScript?
|
||||
|
||||
## --answers--
|
||||
|
||||
Variable types.
|
||||
|
||||
### --feedback--
|
||||
|
||||
Think about what makes a value evaluate as `true` or `false`.
|
||||
|
||||
---
|
||||
|
||||
Loops and functions.
|
||||
|
||||
### --feedback--
|
||||
|
||||
Think about what makes a value evaluate as `true` or `false`.
|
||||
|
||||
---
|
||||
|
||||
Truthy and falsey values.
|
||||
|
||||
---
|
||||
|
||||
Number and string comparisons.
|
||||
|
||||
### --feedback--
|
||||
|
||||
Think about what makes a value evaluate as `true` or `false`.
|
||||
|
||||
## --video-solution--
|
||||
|
||||
3
|
||||
|
||||
## --text--
|
||||
|
||||
What are falsey values?
|
||||
|
||||
## --answers--
|
||||
|
||||
Values that always return `true` in a Boolean context
|
||||
|
||||
### --feedback--
|
||||
|
||||
Think about values that result in `false` when used in conditions.
|
||||
|
||||
---
|
||||
|
||||
Values that evaluate to `false` in a Boolean context, such as `0`, `null`, `undefined`, `false`, `NaN`, and `""`.
|
||||
|
||||
---
|
||||
|
||||
Values that always return `undefined`.
|
||||
|
||||
### --feedback--
|
||||
|
||||
Think about values that result in `false` when used in conditions.
|
||||
|
||||
---
|
||||
|
||||
Values that only work in arithmetic operations.
|
||||
|
||||
### --feedback--
|
||||
|
||||
Think about values that result in `false` when used in conditions.
|
||||
|
||||
## --video-solution--
|
||||
|
||||
2
|
||||
|
||||
## --text--
|
||||
|
||||
Which of these is not a falsey value in JavaScript?
|
||||
|
||||
## --answers--
|
||||
|
||||
Boolean `false`.
|
||||
|
||||
### --feedback--
|
||||
|
||||
Think about which value does not evaluate to `false`.
|
||||
|
||||
---
|
||||
|
||||
`0` (zero).
|
||||
|
||||
### --feedback--
|
||||
|
||||
Think about which value does not evaluate to `false`.
|
||||
|
||||
---
|
||||
|
||||
`" "` (a non-empty string).
|
||||
|
||||
---
|
||||
|
||||
`NaN` (Not a Number).
|
||||
|
||||
### --feedback--
|
||||
|
||||
Think about which value does not evaluate to `false`.
|
||||
|
||||
## --video-solution--
|
||||
|
||||
3
|
||||
Reference in New Issue
Block a user