.
// Create File, Write To File// Close File// Open File, Dump Text To Aray// Close File// Delete File#include #include #include using namespace std;int main(){ string str[1]; ofstream a_file ("Ftest.txt"); a_file<<"File Test"; a_file.close();string line[1]; ifstream b_file ("Ftest.txt"); if (b_file.is_open()) { getline (b_file,line[0]); cout << line << endl; b_file.close(); remove("Ftest.txt"); }}
It'd be simpler still if there weren't one-element arrays, which are confusing to someone that thinks they're there for a reason.
Moreover, str seems to go unused.