main.cxx 419 B

12345678910111213141516
  1. // A simple program that outputs a file with the given name
  2. #include <fstream>
  3. #include <iostream>
  4. int main(int argc, char* argv[])
  5. {
  6. std::ofstream outfile("main.cc");
  7. outfile << "int main(int argc, char* argv[])" << std::endl;
  8. outfile << "{" << std::endl;
  9. outfile << " // Your code here" << std::endl;
  10. outfile << " return 0;" << std::endl;
  11. outfile << "}" << std::endl;
  12. outfile.close();
  13. return 0;
  14. }