swift-collections
swift-collections copied to clipboard
Please Add Support for Multiset
Creating a data structure like a multiset for Swift would indeed be a valuable addition to the standard library. While Swift's Set does not allow duplicates, and arrays can be sorted but don't offer efficient insertion and removal for maintaining sorted order, a multiset could provide efficient operations for both insertion and removal while allowing duplicate elements.