Should
andCode:ofstream s(name.c_str());
give the same results?Code:ifstream s(name.c_str(), ios_base::out);
This is a discussion on file open mode questions within the C++ Programming forums, part of the General Programming Boards category; Should Code: ofstream s(name.c_str()); and Code: ifstream s(name.c_str(), ios_base::out); give the same results?...
Should
andCode:ofstream s(name.c_str());
give the same results?Code:ifstream s(name.c_str(), ios_base::out);
did you mean
in the second line code?Code:fstream s(name.c_str(), ios_base::out);
If I have eight hours for cutting wood, I spend six sharpening my axe.