I wanted to know how I can print out a filename with fstream into another file. For example:
#include<iostream>
#include<fstream>
#include<string>
using namespace std;
int main(int argc, char *argv[])
{
string file;
ifstream myFile(file);
cout << "File: " << file << endl;
}
If i had another .cpp file , how can i print " file " in that also.