Learn JavaScript The Hard Way Has Begun

TLDR:  The JavaScript book is now in full development mode and exercises will start landing this weekend.  I’ve worked out a way to make this book be two books in one and will produce 2160p videos for it.  If you pre-ordered the book at $20 then you received an even greater discount as I’m upping the final published price to $45 instead of $40.  You can see the outline for the book at the end of this article.

I have finally sorted out all the problems related Learn JavaScript The Hard Way. I said that the that the first exercises would start coming down in April, but there were a few issues with the latest release of JavaScript that derailed my original plans for the book. I wanted to wait until I could figure out exactly how to do the book and make it resistant to possible future changes to JavaScript. JavaScript is a very fast-moving language and I didn’t want to be stuck with a obsolete book 2 weeks after I wrote it.

The other issue I had to solve was exactly what platform to support. I originally wanted to support browsers, but those are so diverse in what they allow, and so that I had to abandon that plan. I realized there are plenty of books that teach you how to use JavaScript in the browser, but not many that focus on the basic computer science concepts and fundamentals. So I changed the format and focused just on Node.js.  Node is a little behind on some of the features, but it has enough for people to learn basic JavaScript and complete a bunch of projects.

With the platform solved I then had to figure out a way to update and modernize the style of book that I write. I originally was going to do a book similar to my others, but then I realized I could most likely combine the beginner book (such as Learn Python the Hard Way) with my advanced book Learn More Python the Hard Way. Combining the two structures made for a much more complete book that takes someone from complete beginner to actually finishing many projects in JavaScript.

The final improvement that I worked on was improving the quality of the videos for the JavaScript book. In my last two books for Python I used 1080p as the format and it worked, but it still wasn’t quite enough screen to show multiple windows at the same time. With the JavaScript book I want to show people my actual development environment as I work on the projects. I normally use a really large screen, even larger than 2160p.

I found that beginners develop an unrealistic idea of how programmers actually is done because they see me using a different set up than I actually use when I code. When I code I don’t use a screen that’s 1080 pixels tall. I actually use a screen that is much larger than that and sometimes even used two screens.

For the JavaScript book I wanted to use a large enough video size that people could watch me code as close to how I really code as possible.  On a large monitor, with multiple windows, and without switching windows. To accomplish this I had to do several tests of different video encoding software, recording systems, audio equipment, and also did quite a lot of work in live coding sessions with other students. The end result is that I can now produce 2160p videos with higher quality sound a lot faster and cheaper than I could before.

The Planned Features

Given all that the features of the JavaScript book are going to be the following:

  •  UHD quality video at 2160P resolution, but with smaller files for people with limited download Internet.
  • A combined format that starts from a beginner level and goes all the way to completing many projects of increasing degrees of difficulty, effectively being two books.
  • As with all my books HTML and PDF formats will be available.
  • Focusing on more systems level programming with Node and using the most modern JavaScript I can get away with that Node supports.
  • A total of 62 exercises.

This weekend I will be publishing the first exercises that I’ve written which will be up to exercise 6. This first release will be a draft, and should include most of the videos for those exercises.   I will then be able to post probably three or six videos a week depending on the difficulty of the exercises. The first half of the book is just basics so that’s pretty straightforward, but the second half of the book is actual coding on small projects so those are little more difficult.

Finally, as I said before the price on the book now is $20 and that’s 50% of the final price of the book is done. Because this book is basically two books, and it’s going to use 2160p video the final price for the book is going to be $45 instead of $40. That means you original purchase of $20 is now even more of a discount once the book is released.

Current Table of Contents

Here is a breakdown of everything that I am planning on teaching in the JavaScript book. The goal with the Part I of the book is to get someone just dangerous enough to complete Part II.  In Part II you’ll learn more parts of JavaScript as you make tiny pieces of software.  This makes the JavaScript book much more a “learn by doing” book than before.

  • Part I: Basics
  • Section 1: The Beginning
  • Exercise 00: Gearing Up
  • Exercise 01: A First Program
  • Exercise 02: Comments
  • Exercise 03: Simple Math and Strings
  • Exercise 04: Variables
  • Exercise 06: Escape Sequences
  • Exercise 07: Prompting Input
  • Exercise 08: Command Line Arguments
  • Exercise 09: Files
  • Exercise 10: Files, Args, Variables, Oh My
  • Exercise 11: Functions
  • Exercise 12: Functions, Files, Variables
  • Exercise 13: Modules

You can see that this book goes a little faster than my other beginner books and has a lot less repetition.  By Exercise 13 we’re already loading in external code, writing functions, opening files, and other simple tasks.  In my previous books students didn’t reach this level until Exercise 25.

  • Section 2: Logic and Flow Control
  • Exercise 14: If
  • Exercise 15: If and Else
  • Exercise 16: While Loops
  • Exercise 17: Lists and For Loops
  • Exercise 18: More Lists
  • Exercise 19: Data Objects
  • Exercise 20: First Game

We then get into Logic and Flow Control, where you learn how to make the first useful bits of actual computation.

  • Section 3: OOP
  • Exercise 21: Simple OOP
  • Exercise 22: More Complex OOP
  • Exercise 23: Prototype Inheritance
  • Exercise 24: OOP Game

I then introduce OOP, but it’ll be just enough OOP to be dangerous, in keeping with the theme of Part I.

  • Section 4: FP
  • Exercise 25: Functions and Recursion
  • Exercise 26: Transforming Data
  • Exercise 27: Applying Functions
  • Exercise 28: Scope and Closures
  • Exercise 29: Currying and Accumulators
  • Exercise 30: Events and Callbacks

Modern JavaScript seems to shy away from OOP and go with more of a Functional Programming style, so I’ll spend a bit more time on this way of coding and most likely use it more in Part II.

  • Part II: Projects
  • Section 5: Hacks
  • Exercise 31: Parsing Command Line Arguments
  • Exercise 32: cat
  • Exercise 33: find
  • Exercise 34: grep
  • Exercise 35: cut
  • Exercise 36: sed
  • Exercise 37: sort
  • Exercise 38: uniq

Part II opens up with a series of quick hacks that just implement some basic unix tools in JavaScript.  These are nothing fancy, original, or cool.  The point of this first section of Part II is to get the student to work on the start of a piece of software and comfortable with making garbage.

  • Section 6: Data Structures
  • Exercise 39: Single Linked Lists
  • Exercise 40: Double Linked Lists
  • Exercise 41: Queue and Stack
  • Exercise 42: Sorting Algorithms
  • Exercise 43: Hashmap
  • Exercise 44: Binary Search Tree
  • Exercise 45: Binary Search

We then implement some very simply and naive versions of the classic data structures, and start to focus on quality and testing.

  • Section 7: Testing and Hacks
  • Exercise 46: xargs
  • Exercise 47: hexdump
  • Exercise 48: tr
  • Exercise 49: sh
  • Exercise 50: diff and patch

The student then combines testing and quality with quick hacks to apply their knowledge so far.

  • Section 8: Parsing
  • Exercise 51: Finite Sate Machines
  • Exercise 52: Regular Expressions
  • Exercise 53: Scanners
  • Exercise 54: Parsers
  • Exercise 55: Analyzers
  • Exercise 56: Puny Python
  • Exercise 57: Calculator
  • Exercise 58: BASIC

Section 8 will get into the very basics of parsing programming languages.

  • Section I: Final Projects
  • Exercise 59: blog
  • Exercise 60: bc
  • Exercise 61: ed
  • Exercise 62: sed

Finally, they finish off with a set of open ended projects that are meant to combine everything they’ve learned so far.

Published by


I'm the author of The Hard Way series.