Day 1 · Thursday, Oct 29, 2026 · 2h

Graph day: 3 problems

dsagraphsbfsdfs

Focus area: DSA only. Spent 2 hours on graphs and solved three problems.

What I did

  • Minimum Genetic Mutation: shortest path in an implicit graph, where each gene string is a node and a one-letter change in the bank is an edge. BFS from the start gene.
  • Keys and Rooms: reachability. DFS/BFS from room 0, collecting keys as you go, then check every room was visited.
  • Shortest Bridge: DFS to mark the first island, then multi-source BFS outward from all its cells until you hit the second island.

Pattern of the day

All three are BFS/DFS on a graph that isn’t given as an adjacency list: a grid, a list of rooms, or a set of strings. The work is spotting what the nodes and edges are.