Skip to content

Latest commit

 

History

History
11 lines (6 loc) · 349 Bytes

File metadata and controls

11 lines (6 loc) · 349 Bytes

Problem 133: Clone Graph

Difficulty: Medium

Problem

Given the head of a graph, return a deep copy (clone) of the graph. Each node in the graph contains a label (int) and a list (List[UndirectedGraphNode]) of its neighbors. There is an edge between the given node and each of the nodes in its neighbors.

Example

Self-explanatory