Push adjacent nodes in graph to the queue , if not visited count the number of nodes added to the queue
if curr in graph : NEW_LINE INDENT for i in range ( len ( graph [ curr ] ) ) : NEW_LINE INDENT if ( not visited [ graph [ curr ] [ i ] ] ) : NEW_LINE INDENT q . append ( graph [ curr ] [ i ] ) ; NEW_LINE count += 1 NEW_LINE DEDENT DEDENT DEDENT