Skip to content

Instantly share code, notes, and snippets.

@baharev
Created July 1, 2014 23:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save baharev/731f3c6c8d15320d2336 to your computer and use it in GitHub Desktop.
Save baharev/731f3c6c8d15320d2336 to your computer and use it in GitHub Desktop.
Show contents of the file data.txt in the console
#include <iostream>
#include <fstream>
int main() {
std::fstream in("data.txt");
std::cout << in.rdbuf() << std::endl;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment