3.
Variables or Constants: Which to Use? 35
Literals 36
Primitive Types and Objects 37
Numbers 38
Strings 40
Escaping 40
Booleans 44
Symbols 45
Objects 46
Number, String, and Boolean Objects 48
Arrays 49
Trailing Commas in Objects and Arrays 50
Dates 51
Conclusion 54
4.
while Loops 59
Whitespace 60
for Loop 64
if Statement 65
Control Flow Statements in JavaScript 68
vi | Table of Contents