Self-balancing multiset