Add graph traversal algorithms