Mega Code Archive
Categories
/
C++ Tutorial
/
File Stream
File output with strings
#include
using namespace std; int main(){ ofstream outfile("TEST.TXT"); outfile << "test\n"; outfile << "1\n"; outfile << "2\n"; outfile << "3\n"; return 0; }