#include #include int main() { FILE *fp = fopen("adat.txt", "r"); char *str = (char*) malloc(30 * sizeof(char)); while(!feof(fp)) { fgets(str, 30, fp); if(!feof(fp)) printf("%s", str); } fclose(fp); }