implemented depthFirstSearch method, added test class to test it and it works great!!