Originally Posted by
Salem
Well the first mistake was reading schildt.
And the second was using TurboC as your reference compiler.
I also agree with slcjoey's analysis of your other attempts.
A year of C, and you can't use fgets() in a loop?
damn man! i know how to use fgets()
its just i cant get it right.. look
Code:
while(!feof(fp))
{
fgets(str,50,fp);
printf("%s",str);
strcpy(str,"");
}
this code will put each line of file read in a char array str with new line character. and then print the str in the console.
FIle io is not my prob.. smtimes it becomes tricky to read a file in a way problem wants..
i still didnt get my answer.... how to check my C skills?
may be im a beginner