Skip to main content
CF

Graph Theory Algorithms for Competitive Programming

20h 12m 42s
English
Paid
Updated September 2026

Graph Theory Algorithms for Competitive Programming is a 94-lesson 20 hours 12 minutes self-paced course by Udemy. Graph Theory Algorithms for Competitive Programming , taught in C++ by Google software engineers Prateek Narang and Apaar Kamal, is built around a simple idea: the same graph algorithms behind maps, social networks, and build tools also…

Course facts

Lessons
94
Duration
20 hours 12 minutes
Level
All levels
Language
English
Updated
2026-09-11
Instructor
Udemy
Price
Premium

Graph Theory Algorithms for Competitive Programming, taught in C++ by Google software engineers Prateek Narang and Apaar Kamal, is built around a simple idea: the same graph algorithms behind maps, social networks, and build tools also show up constantly in coding contests.

Two Parts, Two Goals

Part I covers the core concepts — graph storage, BFS/DFS, cycle detection, topological sorting, Union-Find, minimum spanning trees (Prim, Kruskal), and shortest-path algorithms (Dijkstra, Bellman-Ford, Floyd-Warshall) — enough on its own for everyday coding work. Part II goes further into contest-specific territory: flood fill, multisource BFS, strongly connected components, Euler tours, lowest common ancestor, articulation points, and network flow.

How You Practice

  • Guided lessons paired with more than 80 coding problems
  • Step-by-step build-up from basic graph representation to advanced algorithms
  • A structure that lets you stop after Part I if contests aren't the goal

94 lessons in total, mixing theory with code so each algorithm is something you implement, not just read about.

Who teaches Graph Theory Algorithms for Competitive Programming? Udemy

Udemy thumbnail

Udemy is the largest open marketplace for online courses on the internet. Founded in 2010 by Eren Bali, Oktay Caglar, and Gagan Biyani and headquartered in San Francisco, the company went public on the Nasdaq in 2021 under the ticker UDMY. The platform hosts well over two hundred thousand courses across software development, IT and cloud, data science, design, business, marketing, and creative skills, taught by tens of thousands of independent instructors. Roughly seventy million learners use it worldwide, and the corporate arm — Udemy Business — supplies a curated subset of that catalog to enterprise customers.

Because Udemy is a marketplace rather than a single editorial publisher, the catalog is uneven by design. The strongest material lives in the long-form, project-based courses authored by working engineers — full-stack JavaScript, React, Node.js, Python data science, AWS, Docker and Kubernetes, mobile development with Flutter and React Native, and cloud certification preparation. The CourseFlix listing under this source is the slice of that catalog that has been mirrored here for offline-friendly viewing, organized by topic and updated as new releases land. Pricing on Udemy itself swings dramatically with the site's near-permanent sales, which is why the platform is best treated as a deep reference catalog: pick instructors with strong reviews and a track record of updating their material rather than buying on the headline price alone.

What lessons are included in Graph Theory Algorithms for Competitive Programming?

This is a demo lesson (10:00 remaining)

You can watch up to 10 minutes for free. Subscribe to unlock all 94 lessons in this course and access 10,000+ hours of premium content across all courses.

View Pricing
0:00
/
#1: Course Orientation!
All Course Lessons (94)
#Lesson TitleDurationAccess
1
Course Orientation! Demo
07:03
2
Graphs Introduction
12:05
3
Graph Applications
05:49
4
Graph Key Terms
09:08
5
Adjacency List Representation
08:43
6
Adjacency List Representation with Node Class
09:09
7
Breadth First Search
06:44
8
BFS Code
07:16
9
BFS Shortest Path
04:31
10
BFS Shortest Path Code
06:11
11
Snakes and Ladder Solution
08:25
12
DFS Concept
04:19
13
DFS Code
05:41
14
Largest Island Solution
12:31
15
Cycle Detection in Undirected Graph
03:35
16
Cycle Detection in Undirected Graph Code
08:59
17
Directed Graph - Cycle Detection
08:56
18
Directed Graph - Cycle Detection Code
12:47
19
Bipartite Graph
07:15
20
Bipartite Graph Code
12:26
21
Directed Acyclic Graph & Topological Ordering
04:35
22
Topological Sort Algorithm
04:51
23
Topological Ordering BFS Code
05:56
24
Toplogical Order using DFS
04:52
25
Topological Ordering using DFS Code
05:07
26
Disjoint Set Union Introduction
04:20
27
DSU Data Structure - Union & Find Ops
09:02
28
DSU Data Structure
07:07
29
DSU Implementation
13:17
30
Union by Rank
10:16
31
Path Compression Optimisation
08:39
32
DSU Dry Run
13:15
33
Introduction to Minimum Spanning Trees!
03:38
34
Prim's Algorithm
19:33
35
Prim's Code
18:43
36
Kruskal's Algorithm
08:59
37
Kruskal's Code
13:38
38
Introduction to Shortest Path Algorithms
07:53
39
Dijkshtra's Algorithm
09:12
40
Dijkshtra's Algorithm Code
14:55
41
Bellman Ford Algorithm
33:09
42
Bellman Ford Code
09:12
43
Floyd Warshall
29:35
44
Floyd Warshall Code
08:38
45
Solution - Shortest Path in Grid!
12:21
46
Travelling Salesman Problem
12:04
47
Travelling Salesman Intution
03:43
48
TSP Brute Force
12:26
49
TSP DP + Bitmasking
02:44
50
Flood Fill Introduction
05:32
51
Number of Islands
18:19
52
Coloring Islands
07:01
53
Biggest Island
03:30
54
Make Largest island
19:01
55
Introduction to Multi Source BFS
12:12
56
Problem on Multi Source BFS
19:46
57
Bonus Problem on Multi Source BFS
15:51
58
0/1 BFS
07:41
59
Introduction to DFS tree and Backedges
09:07
60
DFS Tree and backedges in Undirected graph
16:41
61
DFS Tree and Backedges in Directed and Undirectde graphs
23:12
62
Print cycle in a graph
10:04
63
Introduction and definitions
12:27
64
Discovered Time
11:33
65
Lowest Time or Low Link
24:48
66
Algorithm
19:20
67
Coding the Algorithm
17:18
68
Introduction to Topological Order and Strongly Connected Components
18:42
69
Algorithm and Code to find Topological Ordering
20:43
70
Introduction to Strongly Connected Component
09:51
71
Condensed Component Graph
12:51
72
Kosaraju Algorithm for Strongly Connected Component
30:06
73
Kosaraju Algorithm for Strongly Connected Component Code
11:47
74
Introduction and properties of trees
24:27
75
DFS on trees
08:03
76
Print all ancestors in a tree
08:36
77
Introduction
11:24
78
Applications
21:51
79
Code
13:04
80
Introduction
12:37
81
LCA (Brute Force)
16:12
82
LCA using Binary Lifting
38:43
83
Introduction and brute force
15:52
84
Approach to re root the tree
20:21
85
Code for re rooting of the tree
11:13
86
Introduction to Network
04:13
87
Introduction to Maximum Flow in a Network
08:40
88
Residual Networks and Augmenting Paths
26:27
89
Ford-Fulkerson and Edmond-Karp Algorithm
26:24
90
Dinic's Algorithm
25:19
91
Dinic's Algorithm Code
33:21
92
Applications of Max Flow as Maximum Bipartite Matching
23:36
93
Board Game
12:12
94
Board Game Code
19:31
Unlock unlimited learning

Get instant access to all 93 lessons in this course, plus thousands of other premium courses. One subscription, unlimited knowledge.

Learn more about subscription

What courses are similar to Graph Theory Algorithms for Competitive Programming?

More courses by Udemy

Frequently asked questions

What prerequisites are needed for this course?
The course requires a basic understanding of C++ programming. Familiarity with fundamental data structures and algorithms will be beneficial, as the course involves implementing complex graph algorithms and concepts such as BFS, DFS, and shortest path algorithms.
What projects or problems will I work on during the course?
The course includes more than 80 problems to solve, covering various graph-related challenges. You will work on problems like the Snakes and Ladders Solution, Largest Island Solution, and the Shortest Path in Grid. These problems help reinforce the concepts covered in the lectures and build practical skills.
Who is the target audience for this course?
This course is designed for individuals interested in competitive programming and those looking to deepen their understanding of graph algorithms. It is suitable for students and software engineers who want to apply graph theory in coding contests and practical applications like map apps and social networks.
How does the course depth and scope compare to similar courses?
The course offers a comprehensive exploration of graph theory algorithms, covering both foundational concepts and advanced topics. It delves into graph storage techniques, cycle detection, topological sorting, and minimum spanning trees, providing a blend of theoretical and practical knowledge not often found in introductory courses.
What specific graph algorithms are covered in the course?
The course covers a wide range of graph algorithms including BFS, DFS, cycle detection in both undirected and directed graphs, topological sorting, disjoint set union, minimum spanning trees using Prim and Kruskal's algorithms, and shortest path algorithms such as Dijkstra, Bellman-Ford, and Floyd-Warshall.
What topics are not covered in this course?
The course does not cover non-graph related algorithms or data structures. It focuses exclusively on graph theory and its applications, so topics like sorting algorithms, basic data structures like stacks and queues unrelated to graph problems, or non-graph competitive programming techniques are not included.
How much time should I expect to commit to this course?
With 94 lessons and a significant number of practical problems to solve, learners should be prepared to invest a substantial amount of time. The exact time commitment will depend on the individual's pace, but consistent effort over several weeks is recommended to effectively grasp the material and complete the exercises.