CommonLounge Archive

Learn Data Structures and Algorithms

December 28, 2016

This 28-part course consists of tutorials on data structures and algorithms. It alternates between tutorials and implementation, and you get to implement every algorithm. You can think of this course as a “Free Online Nano Book”.

This course teaches algorithms and data structures from the ground-up. It starts with why you need algorithms, and then proceeds to teach you sorting algorithms, dynamic programming, and graph algorithms.

The primary objectives of this course are:

  1. Learn efficient algorithms for sorting and searching, such as merge-sort, quick-sort, and binary search.
  2. Learn problem solving techniques such as recursion and divide-and-conquer.
  3. Learn dynamic programming and solve a variety of dynamic programming problems.
  4. Learn data structures such as heaps and disjoint set data structure.
  5. Learn about graphs and graph algorithms such as graph search algorithms, shortest path algorithms, minimum spanning tree.
  6. Implement each of the learnt algorithms and data structures from scratch in Python, C++, Java or any other programming language of your choice.

Most of the tutorials are a combination of video, text and code! The tutorials have been edited and curated meticulously and are some of the best tutorials on each topic available online.


Why algorithms?

This section introduces the concept of algorithms, and defines what it means when we talk about an algorithm’s efficiency.

Your first algorithms!

We’ll start with the greedy algorithm, and after that we’ll learn about recursion.

Binary search is a recursive search algorithm which runs in O($\log n$) time. It’s an example of a divide-and-conquer algorithm.

Sorting algorithms

Sorting algorithms are a set of algorithms that all solve the same problem (sorting) but using very different strategies. These algorithms will introduce you to techniques such as recursion, divide-and-conquer, heaps, etc.

Dynamic Programming

Dynamic programming is a very versatile method, used for solving a wide variety of problems. We’ll introduce dynamic programming by applying it to a problem, and then solve a range of problems using dynamic programming.

Graph Algorithms

In this section, we introduce graphs. Like dynamic programming, graphs are also very versatile. We’ll discuss graph search algorithms like breadth-first search and depth-first search, shortest path algorithms like Dijkstra, and minimum spanning tree algorithms such as Prim’s and Kruskal’s.


© 2016-2022. All rights reserved.