Yeswanth CP
Yeswanth CP
"a" "r+"
Open file for appending, adding Open file for both reading and writing.
data to the end of the file.
File Pointers
End-of-File
Current Position The feof() function can be used to
The file pointer keeps track of the check if the file pointer has
current position within the file. reached the end of the file.
1 2 3
Manipulating Position
Use functions like fseek() and
ftell() to move the file pointer to a
specific location.
F ile Handling F unctions
fclose()
The fclose() function is used to close a file that was previously opened with fopen().
Error Handling
Always check the return value of fclose() to ensure the file was closed successfully.
THANK YOU