On Tuesday, 3 December 2019 at 15:14:03 UTC, ikod wrote: > > Never tried, but depending of the nature of your "something" > you can try bit sets. There are efficient algorithms for large > bit arrays (see "roaring" for example). "roaring" is massive overkill for my case, but thanks for suggesting it. I didn't know about it.