[求助]写文件换行的问题
。。。fstream outfile;
const int s=10;
char buf[s]="";
char t;
cout<<"input computer room:";
cin>>t;
cout<<"input computer number:";
cin.read(buf,s);
。。。
outfile<<"net share k: \\\\tyxy"<<t<<"\\feaxm\\stud"<<buf<<endl;
。。。
昨天没说完全
用上面的程序后写在文件上的是这样的
比说我输入2 回车 25 CRTL+Z,结果是
net share k: \\tyxy2\feaxm\stud
25 回车
如何让它在一行显示
谢谢各位高手指教
回车是我自己写的~~表示此处有个回车