/
ProgrammingIntroduction to Algorithms
← Back to Home
Programming · Module 01

Introduction to
Algorithms

Correctness proofs, asymptotic analysis, and the algorithmic foundations that every quant developer builds on — from sorting to shortest paths, from hash tables to dynamic programming.

13+
Chapters
50+
Practice Problems
2
Languages
0
Cost
Inspired by MIT 6.006 · Introduction to Algorithms · Spring 2020 MIT 6.046J · Design and Analysis of Algorithms · Spring 2015
Implementations in Python 3 C++17 — toggle between languages inside each chapter
What you will learn
📐
Rigorous Correctness
Every algorithm comes with a proof — induction, loop invariants, or contradiction. No hand-waving.
Asymptotic Analysis
O, Ω, Θ notation, recurrence relations, the Master Theorem — how to reason about performance on large inputs.
📈
Trading System Applications
Every major concept connected to real market infrastructure — order books, arbitrage detection, instrument master lookup.

💡
Who this is for. This module assumes comfort with basic programming concepts (variables, loops, functions) but no prior algorithms knowledge. Mathematical maturity at +2 PCM level is sufficient for the proofs. If you are comfortable with the Mathematics module on this site, you are ready.
Chapters 13 chapters · Python + C++
01
Computation Models and Asymptotic Analysis
Word-RAM model, O/Ω/Θ notation, the birthday matching algorithm, correctness via induction, efficiency vs brute force.
Foundational ● Live 4 MCQ
02
Sequences — Arrays, Linked Lists, Dynamic Arrays
Static arrays, linked lists, dynamic arrays; amortised analysis of append; the sequence interface.
Foundational ● Live 4 MCQ
03
Sorting I
Correctness by induction, Θ(n²) vs Θ(n log n), the merge sort recurrence, comparison lower bound.
Foundational ● Live 4 MCQ
04
Hashing
Direct-access arrays, hash functions, collision resolution, expected O(1) lookup — and NSE instrument master as a real application.
Foundational ● Live 4 MCQ
05
Sorting II
Breaking the comparison lower bound, integer sorting, stability — when linear time sorting is possible.
Intermediate ● Live 4 MCQ
06
Binary Trees
Binary search trees, in/pre/post order traversal, BST property invariant, augmentation for order statistics.
Intermediate ● Live 4 MCQ
07
Balanced BSTs
Height invariant, rotations, AVL insertion and deletion — guaranteed O(log n) for all operations.
Intermediate ● Live 4 MCQ
08
Binary Heaps
Heap property, heapify, heap sort, priority queue interface — and order book bid/ask as a heap application.
Intermediate ● Live 4 MCQ
09
Graph Traversal
Graph representations, BFS shortest paths on unweighted graphs, DFS discovery/finish times, cycle detection.
Intermediate ● Live 4 MCQ
10
Weighted Shortest Paths
Relaxation framework, negative weight cycles, graph duplication for Bellman-Ford, greedy correctness of Dijkstra — and currency arbitrage detection.
Intermediate ● Live 4 MCQ
11
Dynamic Programming I
The SRTBOT framework, memoisation vs tabulation, subproblem graphs, topological ordering of computation.
Advanced ● Live 4 MCQ
12
Dynamic Programming II
Longest common subsequence, longest increasing subsequence, coin change, subset sum — and position sizing as a knapsack problem.
Advanced ● Live 4 MCQ
13
Complexity
Decision problems, polynomial time, verifiers, 3SAT, reductions, why optimal portfolio construction is NP-hard in general.
Advanced ● Live 4 MCQ