#include "stdafx.h"
#include <iostream>
#include <map>
int main()
{
std::map<int,int*> m_peoplePhotoId;
int t[8] = {1,2,3,4,4,5,6,7};
m_peoplePhotoId.insert ( std::pair<int,int*>(0,t) ); //另一种插入方式是以数组的方式插入
std::map<int,int*>::iterator tmp = m_peoplePhotoId.find(0);
if(tmp == m_peoplePhotoId.end())
{
std::cout << "没找到!" << std::endl;
return 0;
}
int n = tmp->second[7];
return 0;
}
map「int,int*」
最新推荐文章于 2023-03-10 16:28:18 发布