#include <map>
#include <algorithm>
#include <iostream>

class MyClass {
public:
    int getMin(const std::map<std::string, int>& mymap);
};

int MyClass::getMin(const std::map<std::string, int>& mymap) {
    auto it = std::min_element(std::begin(mymap), std::end(mymap),
                               [](const auto& l, const auto& r) { return l.second < r.second; });
    return it->second;
}

int main() {
    std::map<std::string, int> mymap;
    mymap["key1"] = 50;
    mymap["key2"] = 20;
    mymap["key3"] = 100;

    MyClass mc;
    std::cout << "Minimum value: " << mc.getMin(mymap) << std::endl;

	return 0;
}