分类: C/C++
2010-11-06 15:39:25
chinaunix网友2010-11-06 16:07:10
1. "ios_base::in" means open file for input, "ios_base::app" means "append, or write only to the end of a file". 2. Read and Write position are not separately maintained, there is only one "STREAM POSITION" for each object. Thus, I don't think "ios_base::in || ios_base::app" will make any sense. 3. You could try using just "fstream iofile("c://text.txt");", since the standard assumes "ios::in | ios::out" as default mode. However, it is still not a good idea to do input and output with