implemented breadth-first and depth-first traversal algorithms.
initial method signature for FindMaxFlow