
Andy C. answered 06/10/18
Tutor
4.9
(27)
Math/Physics Tutor
ofstream fileObj("myfile.txt");
if (fileObj.is_open())
{
fileObj << "I can work with the file ";
}
else
{
cout << "something went wrong" << endl;
}