Code :: Blocks编译错误 [英] Code::Blocks Compilation Errors

查看:260
本文介绍了Code :: Blocks编译错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Code :: Blocks中遇到一些问题,这是编译后/时的输出;

I'm having some problems with Code::Blocks, and this is the output after / while compiling;

3|iostream: No such file or directory|
4|error: syntax error before "namespace"|
|In function `main':|
8|error: `cout' undeclared (first use in this function)|
8|error: (Each undeclared identifier is reported only once|
8|error: for each function it appears in.)|
||=== Build finished: 5 errors, 1 warnings ===|

我的代码如下;

// my first program in C++

#include <iostream>
using namespace std;

int main ()
{
  cout << "Hello World!";
  return 0;
}


推荐答案

项目。

文件 - >新建项目 - >控制台应用程序 - > C ++。

File -> New Project -> Console Application -> C++ .

它将设置变量和链接器选项,如基本库。

It will set variables and linker options like basics libraries.

这篇关于Code :: Blocks编译错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆