Graph Pattern

Master the Graph coding pattern with curated problems.

#Title
1617Count Subtrees With Max Distance Between Cities
2359Find Closest Node to Given Two Nodes
2360Longest Cycle in a Graph
2392Build a Matrix With Conditions
2508Add Edges to Make Degrees of All Nodes Even
2608Shortest Cycle in a Graph
2662Minimum Cost of a Path With Special Roads
2714Find Shortest Path with K Hops
2836Maximize Value of Function in a Ball Passing Game
2876Count Visited Nodes in a Directed Graph
2924Find Champion II
2959Number of Possible Sets of Closing Branches
3235Check if the Rectangle Corner Is Reachable
3243Shortest Distance After Road Addition Queries I
3244Shortest Distance After Road Addition Queries II
3265Count Almost Equal Pairs I
3267Count Almost Equal Pairs II
3310Remove Methods From Project
3311Construct 2D Grid Matching Graph Layout
3341Find Minimum Time to Reach Last Room I
3342Find Minimum Time to Reach Last Room II
3376Minimum Time to Break Locks I
3377Digit Operations to Make Two Integers Equal
3378Count Connected Components in LCM Graph
3383Minimum Runes to Add to Cast Spell
3385Minimum Time to Break Locks II
3419Minimize the Maximum Edge Weight of Graph
3435Frequencies of Shortest Supersequences
3481Apply Substitutions
3493Properties Graph
3594Minimum Time to Transport All Individuals
3604Minimum Time to Reach Destination in Directed Graph
3650Minimum Cost Path with Edge Reversals
3656Determine if a Simple Graph Exists
3660Jump Game IX
3710Maximum Partition Factor
3778Minimum Distance Excluding One Maximum Weighted Edge
3873Maximum Points Activated with One Addition
3887Incremental Even-Weighted Cycle Queries
3910Count Connected Subgraphs with Even Node Sum
3928Minimum Cost to Buy Apples II
3970Shortest Path With At Most K Consecutive Identical Characters
3977Minimum Time to Reach Target With Limited Power