小编Spa*_*ing的帖子

变量“std::ofstream outfile”具有初始值设定项,但类型不完整

我已经制作了一个关于此的程序,该程序使用Dev C++CPP创建了很多文件,这个程序也使用 Dev C++ 但现在它显示错误。我的专业是创建模板,但它显示.codeHTMLerror

这是我的一些code

#include <iostream>
using std::cout;
using std::cin;
using std::ofstream;
using std::endl;

void HelloWorld() {
    ofstream outfile ("html1.html");

    outfile << "<html> " << endl;
    outfile << "   <head> <title> Template Hello World </title> </head>" << endl;
    outfile << "   <body> <h1> Hello World! </h1> </body> " << endl;
    outfile << "</html> " << endl;
    outfile << "// Template HTML 2018 " << endl;
    cout << "Created Succesfuly! Directory: …
Run Code Online (Sandbox Code Playgroud)

c++ dev-c++

4
推荐指数
1
解决办法
5945
查看次数

标签 统计

c++ ×1

dev-c++ ×1