Unnamed
public cpp v1 · immutable#include <string>#include <fstream>int main(int argc, char *argv[]){ std::string line; std::ifstream myfile("example.txt"); if( !myfile ) { std::cerr << "Unable to open file\n"; return -1; } while( std::getline(myfile, line) ) std::cout << line << std::endl; return 0; // Return IS NOT a function, there's no need for ()}