#include #include #include #include #include "Student.hpp" template void print(std::map s) { for(auto it = s.cbegin(); it!=s.cend(); it++) std::cout << it->first << " -> " << it->second << std::endl; } int main() { std::pair peter_pan(Student("Peter Pan", 1234), std::string("Wendy House, Neverland")); std::pair mickey_mouse = make_pair(Student("Mickey Mouse", 1235), std::string("Walt Disney World Communications, P.O Box 10040, Lake Buena Vista, Florida 32830-0040 ")); std::map students; students.insert( peter_pan ); students.insert( mickey_mouse ); students[ Student("Peter Pan", 1234) ] = std::string("Home Under The Ground, Neverland"); students[ Student("Minnie Mouse", 1240) ] = std::string("Walt Disney World Communications, P.O Box 10040, Lake Buena Vista, Florida 32830-0040 "); print(students); }