remember that returning a std::map by value is not good
I would not agree if this code was meant to run online