开发者

Netbeans C++ Program has no terminal output

开发者 https://www.devze.com 2023-04-02 00:26 出处:网络
It\'s not a weird program. It\'s a simple C++ Hello World program, and for whatever reason there is no output to the terminal either in the terminal or in the output window. Here\'s my \"code\".

It's not a weird program. It's a simple C++ Hello World program, and for whatever reason there is no output to the terminal either in the terminal or in the output window. Here's my "code".

#include <cstdlib>
#include <iostream>

using namespace std;

int main(int argc, char** argv) {
    cout << "Hello there pee开发者_StackOverflowps!";
    cout << endl;
    system("pause");
    return 0;
}

Using Netbeans 6.9 on Ubuntu 11.04 Natty


You may try this:

Project properties -> Run -> Console Type and select Standard Output there.

If this is already selected test with Internal Terminal.


Try installing xterm, that worked for me. (On fedora 18, but Ubuntu should be similar)

sudo apt-get install xterm

or

sudo yum install xterm
0

精彩评论

暂无评论...
验证码 换一张
取 消