ITI0140 Depth First and Breadth First algorithms implemented