Skip to content

Usage as a backend for a SET-like datastructure #8

@thestics

Description

@thestics

I want to use your implementation for my data structure.
In particular set would behave like this:

s = set()
s.add(1)
s.add(2)

# Logarithmic search
one_present = 1 in s

# Only one 2 is present
s.add(2)

As you might notice, in this case, the insertion of an already existing Node would just override the existing one, not insert it somewhere else.
Do you think this is a useful addition and should I create a PR with that patch, or you're fine with the current implementation?

Cheers!

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