1.

Select the action of the method long seek()?(a) Attempts to readup to count bytes into buffer starting at buffer[offset](b) Writes a single byte to an output stream(c) Sets the current position in the stream to the specified offset from specified origin and hence returns the new position(d) None of the mentionedI have been asked this question in final exam.I want to ask this question from Introduction of Stream Classes in portion Console I/O Operations and Stream Classes of C#

Answer»

The CORRECT ANSWER is (c) Sets the current position in the stream to the SPECIFIED offset from specified origin and HENCE returns the new position

To explain I would say: LONG Seek(long offset, SeekOrigin origin)

Sets the current position in the stream to the specified offset from the specified origin. It returns the new position.



Discussion

No Comment Found

Related InterviewSolutions