> But they are both map and set structures just each version has other guarantees that in some scenarios may be more or less useful.
And similarly, linked lists and arrays are just different "versions” of the same data structure: a list.
Re:The Janet Language
by mirekrusin on Saturday February 18, 2023 @04:24PM
(#34851250)
Let's simplify it even more - everything is just ones and zeroes.
You interpreted my reply as “all sets and maps require hashing“ instead of “sets and maps are examples of data structures that can require hashing”… which they are.
Imagine someone says, every fruit in the world is sour, and someone answers, no there are plenty of fruits that are sweet, such as apples, and then an entire thread gets launched in an irrelevant direction pointing out that actually some apples are sour. That’s effectively what’s been done here, and it’s a waste of everyone’s time.
std::set and std::map should be std::ordered_set and std::ordered_map sts::unordered_set and std::unordered_map should be std::hash_set and std::hash_map
If this were so then it might make the incorrect usage of these two options less prevalent. But they are both map and set structures just each version has other guarantees that in some scenarios may be more or less useful.