Udemy
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
JavaScript Data Structures and Algorithms for Interviews
New

JavaScript Data Structures and Algorithms for Interviews

Solve 75 coding interview problems in JavaScript, from brute force to optimal, with real tests, benchmarks and Big O
Created byBig O Bench
Last updated 11/2026
English
English

What you'll learn

  • Solve 75 common coding interview problems in JavaScript, from a first working attempt to a fast solution
  • Work out the time and space complexity of your code with Big O, and explain it out loud
  • Use hash maps and sets, two pointers, sliding windows, binary search, stacks and linked lists
  • Build and traverse trees, tries and graphs, with depth first search, breadth first search and topological sort
  • Write recursive, backtracking, greedy and dynamic programming solutions
  • Test your solutions with Jest and time them on large inputs to see how they grow
  • Step through code in a debugger until every value makes sense

Course content

12 sections • 138 lectures • 19h 13m total length
  • Course intro1:38
  • Set up your machine10:08
  • Time complexity and Big O32:06
  • Space complexity and extra space8:50

Requirements

  • Basic JavaScript: variables, functions, arrays, objects and loops
  • A computer with Node.js 20 or newer and a code editor; the first lecture shows the setup on Mac and Windows
  • No computer science background needed: each new idea gets its own lesson before it's used

Description

This course contains the use of artificial intelligence.

I'm not a native English speaker, so the narration uses an AI voice, which keeps every explanation clear and easy to follow. AI tools also helped me prepare the lessons. I reviewed every lecture myself, and all the code, tests and timings you see were run for real.

Coding interviews still ask algorithm questions, and frontend interviews are no exception. You'll be asked to solve a problem in JavaScript, explain your thinking, and say how fast your code is. This course gets you ready for all three, one problem at a time.

It covers 75 problems that come up again and again, plus 9 lessons that build each new idea from scratch before you need it: Big O, space complexity, recursion, linked lists, trees, graphs, dynamic programming and binary numbers. That's 137 lectures and about 19 hours of video, in the order to learn them.

How every problem is taught

Every problem follows the same path, so you always know where you are:

  1. The problem in plain words, with examples revealed one at a time, including the edge cases like an empty input or a single element.

  2. A first working attempt: the simple solution, coded and tested.

  3. Why it's slow, explained on the code and, wherever speed is the point, timed on a large input.

  4. The better idea, drawn as a picture before any code.

  5. The fast solution, written one line at a time, with each line explained before it's typed.

  6. The tests again, and the same benchmark on the fast version, so you see the difference instead of just hearing about it.

  7. Time and space complexity, worked out on the code itself.

  8. A dry run in the debugger, until every value makes sense.

  9. The common mistakes, and how to avoid them.

The timings are real. In the first problem, checking 40,000 numbers for a duplicate takes about 580 milliseconds the simple way and under 7 milliseconds with a Set.

What's covered

  • Getting started: setting up your machine, time complexity and Big O, space complexity

  • Arrays and hashing: hash maps and sets, anagrams, the longest consecutive sequence

  • Two pointers and sliding window: trapped water, triplet sums, the longest substrings

  • Sorting and binary search: recursion and the call stack, bubble, insertion, merge and quick sort, binary search on rotated arrays

  • Intervals and custom sorting: merging intervals, meeting rooms

  • Stacks and linked lists: building both from scratch, reversal, cycle detection, merging K sorted lists

  • Trees and tries: building a binary tree, level order traversal, validating a binary search tree, a prefix tree, word search

  • Graphs: depth first and breadth first search, islands, connected components, cloning, topological sort

  • Backtracking: combinations for a target sum

  • Matrices and greedy: spiral traversal, rotation, the maximum subarray, reaching the end of an array

  • Dynamic programming: from scratch, then 12 problems from climbing stairs to the longest common subsequence and palindromes

  • Bit manipulation: binary numbers, counting bits, adding without the plus sign

What you get

  • 137 lectures, about 19 hours of 1080p video, each with English captions

  • A practice folder with all 75 problems: an empty practice file, its Jest tests, a benchmark, and the solutions from the video

  • A setup lecture for Mac and Windows, so the tests run on your machine from the first day

How to take this course

Follow the lectures in order, since each lesson prepares the problems after it. Before you watch a solution, try the problem in its practice file and run the tests. Then watch, compare, and run the benchmark on both versions.

By the end, you'll know how to solve these problems in JavaScript, how fast your code is, and why.

Who this course is for:

  • JavaScript and frontend developers preparing for coding interviews
  • Self taught developers and bootcamp graduates who want the computer science foundations
  • Computer science students who want to practice interview problems in JavaScript
  • Developers who want to understand data structures and algorithms rather than memorize solutions