some map-like structure in C++?
To be precise I want to code something like dicts in Python and save an array as a value. ("key" will be long double, array will be unsigned long long)
You could implement an open addressing cuckoo hashmap. They are generally quite fast (in the real of nanoseconds to 2 microseconds) and since your keys are long doubles and value unsigned long longs you can split the double in two to generate the second and first hashes
std::unordered_map
Обсуждают сегодня