Copyright
Brief Table of Contents
Table of Contents
Foreword
Preface
Acknowledgments
About this Book
1. Core concepts on the console
Chapter 1. Programming, JavaScript, and JS Bin
1.1. Programming
1.2. JavaScript
1.3. Learning by doing and thinking
1.4. JS Bin
1.4.1. JS Bin panels
1.4.2. Following the code listings on JS Bin
1.4.3. Logging to the console
1.4.4. Code comments
1.4.5. Further Adventures
1.4.6. Error messages
1.4.7. Line numbers
1.4.8. Get an account
1.5. The Crypt—our running example
1.5.1. Playing The Crypt
1.5.2. Steps for building The Crypt
1.6. Further examples and practice
1.7. Browser support
1.8. Summary
Chapter 2. Variables: storing data in your program
2.1. What is a variable?
2.2. Declaring variables and assigning values
2.2.1. Declaring variables
2.2.2. Assigning values to variables
2.2.3. One-step declaration and assignment
2.2.4. Using a variable in its own assignment
2.3. Choosing good variable names
2.3.1. Keywords and reserved words
2.3.2. Rules for naming variables
2.3.3. camelCase
2.3.4. Use descriptive variable names
2.4. The Crypt—player variables
2.5. Summary
Chapter 3. Objects: grouping your data
3.1. A need for organization