Skip to main content
Interview

Graph problems that keep appearing in interviews - a compilation

Sachin AhujaSachin Ahuja
9/7/2025
192

After giving 15+ interviews this year, here are graph problems I've seen repeatedly:

BFS/DFS based:

  • Number of islands
  • Clone graph
  • Word ladder
  • Rotten oranges

Shortest path:

  • Network delay time (Dijkstra)
  • Cheapest flights within K stops

Topological Sort:

  • Course schedule I and II
  • Alien dictionary

Union Find:

  • Number of connected components
  • Accounts merge

If you can solve all of these comfortably, you'll handle 90% of graph questions in interviews imo.


graphsinterview-prepcompilationdsa

Comments (4)

Sign in to join the discussion.
Shivam Goyal
Shivam Goyal10/3/2025

I keep messing up on 'Network delay time'. I always mix up Dijkstra and Bellman-Ford. Any advice?

Ritesh Pandey
Ritesh Pandey9/29/2025

Do you think these problems cover other graph concepts like bipartite graphs or Euler circuits? Haven't seen them mentioned.

Vera Chen
Vera Chen9/28/2025

Wow, this is super helpful! How often did you get asked about topological sort problems? They seem a bit niche to me.

Anna Mueller
Anna Mueller9/11/2025(edited)

I'm having trouble with the 'word ladder' problem. Any tips for tackling it efficiently?