标签:bsp 文件 main txt pac == class erro return
源程序:
#include <iostream>
using namespace std;
int main()
{
int x, y;
cin >> x >> y;
freopen("c:\\test.txt", "w", stdout);
if (y == 0)
cerr<<"error."<<endl;
else
cout << x << "/" << y << "=" << x / y << endl;
system("pause");
return 0;
}
运行结果:
输入:9 3
在c盘上产生文本文件test.txt,内容为:9/3=3
标签:bsp 文件 main txt pac == class erro return
原文地址:https://www.cnblogs.com/duanqibo/p/12235657.html