The Javascript Newbie’s Handbook
The second console.log() call above might be executed it doesn’t matter what value you assign to the balance variable. This occurs because the code contained in the if statement is just executed when the situation is true. The if assertion permits you to create a program that runs only if a specific situation is met. […]
