Implemented traversal (BFS & DFS) iterators for graphs