Title:
JavaScript IF Statements
Updated:
October 26, 2023
Task/Activity:
  1. Questions
  2. Coding Problems
A. Questions
  1. Why is an IF statement known as a control structure?
Because it allows the developer to control what code is executed.
  1. There are other control structures in JavaScript that we'll be learning about soon. Use your google skills to look up the other control structures in JavaScript and list them below.
There are other control structures like if-else, switch, while, do-while, and for.
  1. What is a boolean expression?
A boolean expression is essentially an equation that declares whether a statement is true or false.
  1. What is the 'equality operator', and what is it used for? How is it different from the assignment operator?
The equality operator is a way to measure whether one value is the same as the other, rather than a declaration of what one value is going to be.
  1. Why is it important to properly indent your code when writing IF statements?
Because code gets very confusing very quickly when you don't format your information properly.
  1. What is a code block in JavaScript?
A code block is the information within a control structure that is executed when the control structure allows it.