Skip to main content

Coding algorithms in front end interviews

We are now part of GreatFrontEnd!

Front End Interview Handbook is now part of GreatFrontEnd! We are working to migrate the content over and you may find the latest version of this page on GreatFrontEnd.

Front End Engineers are also Software Engineers after all, and it's an expectation that Front End Engineers have basic competency in algorithms and data structures. It is possible and reasonable that you will be asked to solve algorithmic questions during your front end interviews and most likely you will be expected to use JavaScript.

Trees are a commonly-encountered data structure in Front End development because the DOM is a tree, so if you have to prioritize, definitely focus on being good at tree data structures and common algorithms for trees, such as Breadth-first Search and Depth-first Search.

The Tech Interview Handbook goes into great detail about preparing for Algorithms questions.

Go to Tech Interview Handbook  →

Free practice questions

GreatFrontEnd

GreatFrontEnd provides free questions for you to practice implementing Data Structures and Algorithms in JavaScript. You can practice implementing common data structures (e.g. Stacks, Queues) and algorithms (e.g. Binary Search, Merge Sort). Check it out →

Algorithm courses

AlgoMonster

AlgoMonster aims to help you ace the technical interview in the shortest time possible. By Google engineers, AlgoMonster uses a data-driven approach to teach you the most useful key question patterns and has contents to help you quickly revise basic data structures and algorithms. Best of all, AlgoMonster is not subscription-based - pay a one-time fee and get lifetime access. Check it out →

Grokking the Coding Interview: Patterns for Coding Questions

This course by Design Gurus expands upon the questions on the recommended practice questions but approaches the practicing from a questions pattern perspective, which is an approach I also agree with for learning and have personally used to get better at coding interviews. The course allows you to practice selected questions in Java, Python, C++, JavaScript and also provides sample solutions in those languages. Learn and understand patterns, not memorize answers! Check it out →

JavaScript courses

If you want more structured algorithms practice which are targeted at JavaScript, check out the following courses.

CourseReviewsDurationPriceContents
Master the Coding Interview: Data Structures + Algorithms4.6/519.5h$$Basic data structures and algorithms, job application, behavioral interview, negotiation
JavaScript Data Structures and Algorithms Masterclass4.5/545h$Basic and advanced data structures and algorithms
Ace the JavaScript Coding Interview-87h$Basic data structures and algorithms, system design, object-oriented design