摘要:
#include <iostream>#include <string.h>#include <stdio.h>#include <map>using namespace std;typedef map <int ,string> templatemap;templatemap testmap;templatemap::iterator Find(int nID){return testmap.find(nID);}string GetElement(int nID){templatemap::iterator iter = Find 阅读全文
摘要:
例子: string s, ss; . s = "The rain in Spain falls mainly in the plain."; ss = s.substr(12, 5); //Spain s.substr(12) //Spain falls mainly in the plain. 阅读全文