Skip to content

Commit dcf95ea

Browse files
file_write.cpp
1 parent 8d04930 commit dcf95ea

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

file_write.cpp

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#include <iostream>
2+
#include <fstream>
3+
using namespace std;
4+
5+
//http://www.cplusplus.com/doc/tutorial/files/
6+
7+
int main () {
8+
ofstream myfile;
9+
myfile.open ("example.txt");
10+
myfile << "Writing this to a file.\n";
11+
myfile.close();
12+
return 0;
13+
}

0 commit comments

Comments
 (0)