Skip to content

Time complexity increases too much!! #1

Description

@kediamanav

You could use a visited array to mark the points that have been visited, that would greatly reduce the number of calls to region_query, which in your case is being called multiple times even for a single point. But if you use a visited array, you would only have to call the region_query once for each point.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions