Category: c
-
Open a file and output numbers
#include #include void accessFile(); int main() { accessFile(); return 0; } void accessFile() { FILE *fp; int n = 0; int z = 0; fp = fopen(“count.txt”,”a+”); if(fp == NULL) printf(“Error opening file”); else { while(!feof(fp)) […]