added printing statement so we see the order of node visits
dfs complete