On Wed, 20 Jun 2018 17:15:59 +0200, Rosario19 <R...@invalid.invalid>
wrote:
Some sort of binary tree will have those performance requirements. But
you'll want to pick a type that's self-balancing. Red-black trees are
a fairly simple, and popular, choice.
Some tree structures can handle duplicate keys, others can't, but even
the ones that can't, can be adapted by adding a sequence number to
each element, and using that as the low part of the key.