Depth First Search
Category: Graphs
```
Problem Statement
(Problem statement not extracted)
```
Approach & Solution
Solution 1
```java
import java.util.*;
class Program {
static class Node {
String name;
List
```
Code Template
```java import java.util.*;
class Program {
// Do not edit the class below except
// for the depthFirstSearch method.
// Feel free to add new properties
// and methods to the class.
static class Node {
String name;
List
public Node(String name) {
this.name = name;
}
public List<String> depthFirstSearch(List<String> array) {
// Write your code here.
return null;
}
public Node addChild(String name) {
Node child = new Node(name);
children.add(child);
return this;
}
} }
```