📅  最后修改于: 2022-03-11 14:44:48.381000             🧑  作者: Mango
void readFile()
{
ifstream file;
file.open ("program.txt");
if (!file.is_open()) return;
string word;
while (file >> word)
{
cout<< word << '\n';
}
}