Subtle insertion bug with std::map
If you try to access an element in a std::map using a key that doesn't exist already in the map, it will insert a default-constructed value with that key. This will lead to unexpected behavior if you're not aware that the insertion has occurred.
std:...
cppnuggets.hashnode.dev1 min read