Hi everyone,
I have to create 16 separate files for 16 nodes and write something in it.
Is there any way in which i do not have to separately create sixteen files.
//// sompe part of code which i am using
file2.open("Node0.txt");//Node0.txt is the file of ofstream type
{
cout<<"I received a packet from node 0";
file2<<" Hello I received a packet from node 0";
file2.close();
}