This course is a first look at the JavaScript you need to write small programs straight away: names, strings, decisions, loops, functions, arrays, and objects. It’s a quick tour, and more detailed courses on each topic come after it. JavaScript does these everyday things its own way, and the course shows you where that won’t match your Python instincts.
Here’s one of those places. A bike-share’s dock report, in Python, works out how many bikes the
van should load, skipping the docks closed for repairs with if dock["name"] in closed:. It
prints this:
Van load: 6
Ported line for line to JavaScript, with if (dock.name in closedDocks) {, the script runs
without an error and prints this:
Van load: 11
This course shows you why, and what a JavaScript developer writes instead.
You’ll help a city bike-share’s rebalancing crew, who drive a van between docking stations, moving bikes from full docks to empty ones. Before each shift, a short Python script reads the dock list and prints which docks are empty, which are nearly full, and how many bikes the van should start with. The crew lead wants it in JavaScript, next to the operator’s other JavaScript tools, and you’ll port it one piece at a time.
By the end of this course, you’ll be able to:
- Name values with
constandlet, and build strings with template literals where Python uses f-strings - Make decisions with
ifandelse, and loop over an array withfor...of - Write functions with
function, and small ones as arrows - Use arrays as lists and objects as dicts
- Spot the few places where a line-for-line port from Python goes wrong
- Port a small Python script to JavaScript and run it
You only need to know how to write small Python programs with variables, f-strings, if,
for loops, functions, lists, and dicts. In JavaScript, you only need to know how to run a
.js file with node and print with console.log().
You’ll also need Node installed. The Getting Started course sets it up, or you can get it from nodejs.org. A current version of Node.js and of Python is fine: the examples use Node 26 and Python 3.15.
The course mixes short videos and text lessons, with exercises where you write the code yourself. Every video has a summary below it, so you can review without rewatching. A project puts the dock report together, and a quiz and a summary close the course.
Next up: Naming Values With const and let, where you declare the report’s first values.