Created
March 2, 2021 06:35
-
-
Save vineethm1627/3c8815885cd703b29970320284dd21dc 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 <iostream> | |
#include <fstream> | |
using namespace std; | |
int main() { | |
ofstream MyFile; | |
// open the file | |
MyFile.open("test.txt"); | |
MyFile << "Some text. \n"; | |
// close the file. | |
MyFile.close(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Reading information from the file, line by line.