Question about fgets?

Yes fgets() always properly null-terminates the buffer. From the man page : The fgets() function reads at most one less than the number of characters specified by n from the given stream and stores them in the string s Reading stops when a newline character is found, at end-of-file or error. The newline, if any, is retained.

If any characters are read and there is no error, a 0 character is appended to end the string.

Yes fgets() always properly null-terminates the buffer. From the man page: The fgets() function reads at most one less than the number of characters specified by n from the given stream and stores them in the string s. Reading stops when a newline character is found, at end-of-file or error.

The newline, if any, is retained. If any characters are read and there is no error, a '\0' character is appended to end the string.

The fgets() function reads at most one less than the number of characters specified by n from the given stream and stores them in the string s. A newline character is found, at end-of-file or error. The newline, if any, is retained.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions