NIELIT O Level Exam

What is the use of seek() method in files?

What is the use of seek() method in files?

फाइलों में seek() फंक्शन का क्या उपयोग है?

A. sets the file's current position at the offset

B. sets the file's previous position at the offset

C. sets the file's current position within the file

D. None of these




Correct Answer is :

A. sets the file's current position at the offset



Explanation
In Python, the seek() method is used to change the current file position or cursor position within a file. The file position is the position where the next read or write operation will occur. The seek() method allows you to move the cursor to a specified offset within the file.
CCC Online Test Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Online Exam Quiz O Level NIELIT Study material and Quiz Bank SSC Railway TET UPTET Question Bank career counselling in allahabad Best Website and Software Company in Allahabad Website development Company in Allahabad