2013年3月算法练习(五) 文件输入、输出 .

来源:互联网 发布:网络平面广告图 编辑:程序博客网 时间:2024/05/29 23:48
#include<iostream>#include<fstream>#include<string.h>using namespace std;int a(void){return 110333;}int main(int argc,char *argv[]){ofstream oftest;char filename[19]="huahua.txt";oftest.open(filename,ios::out);oftest <<a()<<endl<<"huahuahua"<<endl;oftest.close();oftest.clear();return 0;}


 

原创粉丝点击