This shows you the differences between two versions of the page.
cpp:fstream [2013/06/13 18:46] Anthony created |
cpp:fstream [2024/02/16 00:48] (current) |
||
---|---|---|---|
Line 13: | Line 13: | ||
// write to a file | // write to a file | ||
file.write("hello world!"); | file.write("hello world!"); | ||
+ | |||
+ | // close file | ||
+ | file.close(); | ||
} | } | ||
</code> | </code> |