used generic graph traversal in most cases