Experimenting with DFS, but need to handle some things.