2737. Find the Closest Marked Node
ArrayGraph TheoryHeap (Priority Queue)Shortest Path
Hints
Hint 1
Find the distance from s to all nodes.
Hint 2
You can use Dijkstra to find them.
Hint 3
Find the minimum distance between marked nodes.
Preparing judge…