An else block runs when the if condition is false. Exactly one of the two
branches runs.
const isOpen = false;
if (isOpen) {
console.log("Come in");
} else {
console.log("Closed");
}This displays Closed.
Use if and else to display Homework ready when hasHomework is true and
Finish homework otherwise.