import java.util.*; public class Solution { public void dfs(int node, int father, int dep, int[] path, int[] depth,String[] mat) { &nb...