About saving to file

Hi guys.. I was wondering how can I write at the beggining of the file??
file inputs
Lester
Mark

I want it to be
Samonte
Lester
Mark
You will have to put the write position at the beginning of the file, using seekp(). Have a look at this page, under the "get and put stream pointers" section: http://cplusplus.com/doc/tutorial/files/
Topic archived. No new replies allowed.