ifstream input("c:\\a.txt");
if(!input)
{
cerr << "error!";
}
string line, word;
string Array[3][4];
int m(0), n(0);
while (getline(input, line)) //读取每行的字符
{
istringstream isstream(line);
while (isstream >> word) //读取该行用空格隔开的单个数据
{
Array[m][n] = word;
++n;
}
++m;
n = 0;
}
input.close();