Created
March 29, 2016 03:58
-
-
Save b4284/89ff23cb065130301d17 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <fstream> | |
| auto try1(void) { | |
| std::ofstream outfile("/tmp/k.txt"); | |
| return outfile; | |
| } | |
| int main(void) { | |
| auto outfile = try1(); | |
| outfile << "this is an string from c++" << std::endl; | |
| return 0; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment