File handling Doubt

Please explain Seek and Tail functions

@sathsaran01

seek() function is used to change the position of the File Handle to a given specific position. File handle is like a cursor, which defines from where the data has to be read or written in the file.

The tell() method returns the current file position in a file stream.

Note : - You can change the current file position with the seek()
method.

1 Like

Doubt in File handling quiz…

Is there any function called writeline()?

if so,

What is the difference between writeline() and writelines() ?

@ezathwafeeq97

WriteLine method to write the result to the output file.

writelines() method is used to write a list of strings in an opened file.

write() is used to write a string to an already opened file

Understand the other 2 functions.
But, Could you please help me with WriteLine method example or any link for understanding?