#include "stdio.h"
#define M 300
#define N 50
void main()
{
int i,j;
float a[M][N]={0};
FILE *fp;
if((fp=fopen("test.txt","rt"))==NULL)
{
printf("cannot open file\n");
return;
}
for(i=0;i
for(j=0;j
fscanf(fp,"\n");
}
fclose(fp);
for(i=0;i
for(j=0;j
printf("\n");
}
}
读取文件
读取字符
字符转换为浮点数double atof( const char *string )