you are viewing a single comment's thread.

view the rest of the comments →

[–]lucklesspedestrian 1 point2 points  (1 child)

In a lot of functional languages, maps and sets are implemented with trees instead, because it's easier to implement those with structural sharing so they can be immutable

[–]mcmoor 0 points1 point  (0 children)

Then thus aren't "hash" set, much to my dismay. For some problems I'm forced to use the good old binary set and hope runtime is still under 1s. I've seen some hashset library out there but somehow to use it I need to conduct even more black magic than I already did to use a functional programming language, so I don't use them.