This function is related to the file handling of ‘C’. This function moves the file pointer to a specific position in a file. The general syntax of fseek() function is as following:-
fseek(fptr,offset,mode) where fptr indicates the file pointer of a file, offset indicates how many position moves forward or backward the file pointer which depends on mode and mode indicates from where file pointer should move. If mode = 0 it means from the beginning of the file, if mode = 1 it means from the current position, or if mode = 2 it means from the end of the file.