文件名称:二叉树实验
文件大小:1.05MB
文件格式:7Z
更新时间:2017-05-19 05:39:38
数据结构 二叉树 算法
void load_bitre_file(bitre &t,char ss[100]) //构建文件二叉树 { char bs[6];int x;FILE *ff; ff=fopen(ss,"r"); if(ff==NULL){ printf("\ncan't open file!\007"); exit(1); } fscanf(ff,"%s",bs); while(fgetc(ff)!='\n'); fscanf(ff,"%d",&x); while (fgetc(ff)!='\n'); if(strcmp(bs,"bitre")) printf("file error!\007"); else if(x==1) t=NULL; else load(t,ff); fclose(ff); }