大家帮我看下这个程序的错误(在线等)~~
#include <fstream>
using namespace std;
//-------------------------------------
int main(){
ifstream in( "a.in ");
ofstream out( "a.out ");
for(string str; getline(in, str); )
out < <str < <endl;
}
程序编译的时候提示有一个错误
“error C2065: 'getline ' : undeclared identifier”
不知道怎样修改
有那位大虾知道的请指教```
[解决办法]
#include "string "
[解决办法]
#include <string>
[解决办法]
你觉得有这种格式的文件吗?
换成a.txt试试