geany not working for basic c++ program
Asked by
Corey Daley
Hi, I was trying to do some simple programs (learning) and I attempted to create, compile, and run this following program:
#include <iostream>
using namespace std;
int main ();
{
cout ( "Hello World!" );
getchar();
return 0;
}
What I got when I attempted to compile it was this:
g++ -Wall -c "first.cpp" (in directory: /home/corey/
first.cpp: In function 'int main()':
first.cpp:6:24: error: no match for call to ' (std::ostream) (const char [13])
first.cpp:7:10: error: 'getchar' was not declared in this scope
Compilation failed.
If anyone can help me that would be great!
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- Ubuntu geany Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- Corey Daley
- Solved:
- Last query:
- Last reply:
To post a message you must log in.