#include <map>
#include <string>
#include <iostream>
int main()
{
        std::map<int, std::string> myMap =
               {{ 1, "One"},
                {2, "Two"},
                {3, "Three"},
                {7, "Seven"}};

        auto i = myMap.upper_bound(6);
        std::cout << (--i)->first << '\n';
}