fork download
  1. #include <stdio.h>
  2. #include <iostream>
  3. #include <map>
  4. #include <string>
  5.  
  6. int main(void)
  7. {
  8. std::map<std::string,
  9. std::map<std::string,
  10. std::map<std::string, std::string>>> m{{"HARDWARE\\DESCRIPTION\\System\\BIOS",
  11. {{ "REG_SZ",
  12. {{ "SystemSKU", "SystemSKU" }}
  13. }}
  14. }};
  15.  
  16. std::cout << "size of map : "<< m.size() <<std::endl;
  17.  
  18. m.insert({"HARDWARE\\DESCRIPTION\\System\\BIOS1", {{ "REG_SZ1", {{ "SystemSKU1", "SystemSKU2" }}
  19. }}
  20. });
  21.  
  22. std::cout << "size of map after insert: "<< m.size();
  23. return 0;
  24. }
Success #stdin #stdout 0s 3476KB
stdin
Standard input is empty
stdout
size of map : 1
size of map after insert: 2