Citrix OA Question 2024 July | Graphs | on-campus
Question · Posted Jun 2026
Question: Clone Graph Problem Statement Given a reference of a node in a connected undirected graph, return a deep copy (clone) of the graph. Each node in the graph contains a value (int) and a list (List[Node]) of its neighbors. class Node { public int val; public List<Node> neighbors; } Note: The given node will always be the first node with val = 1. You must return the copy of the given node as a reference to the cloned graph. ...
The full answer & interview discussion are available to premium members.
Log in Create a free account