Inside one of my functions that are being called by the main()
, I have the following very simple testing snippet.
ofstream outFile;
outFile.open("C:\\Program Files\\data\\test.txt");
outFile << "test\n";
outFile.close();
After running the code, I didn't see the file appears. Why is it so?