Cursos /
Introduction to JavaScript
Challenge: Comparing Variables
Task
We have three variables in this task: a = 33
, b = 26
, and c = "26"
. We will perform various comparing operations on these variables.
- Check if
a
is equal tob
. - Check if
b
is strictly equal toc
. - Determine if
a
is greater than or equal toc
. - Find out if
b
is less thanc
. - Check if
a
is greater thanb
AND ifb
is equal toc
. - Check if
a
is equal tob
OR ifc
is less thana
.
The output should be:
- Use the comparison operators:
==
,===
,>=
,<
,>
. - Use the logical operators: AND (
&&
) and OR (||
).
¿Todo estuvo claro?
Sección 3. Capítulo 8
Contenido del Curso
Introduction to JavaScript
4. Conditional Statements
Introduction to JavaScript
Challenge: Comparing Variables
Task
We have three variables in this task: a = 33
, b = 26
, and c = "26"
. We will perform various comparing operations on these variables.
- Check if
a
is equal tob
. - Check if
b
is strictly equal toc
. - Determine if
a
is greater than or equal toc
. - Find out if
b
is less thanc
. - Check if
a
is greater thanb
AND ifb
is equal toc
. - Check if
a
is equal tob
OR ifc
is less thana
.
The output should be:
- Use the comparison operators:
==
,===
,>=
,<
,>
. - Use the logical operators: AND (
&&
) and OR (||
).
¿Todo estuvo claro?
Sección 3. Capítulo 8