Divide top by D [ i ] if it is possible and push the result in q
if ( d [ i ] != 0 and top % d [ i ] == 0 and ( top // d [ i ] not in visited ) ) : NEW_LINE INDENT q . append ( top // d [ i ] ) NEW_LINE visited [ top // d [ i ] ] = True NEW_LINE DEDENT