I Can't Run Program Error message :
Here's the code:
#include <iostream>
using namespace std;
int main()
{ cout << "C++"; return 0;
} 1 Answer
First install the compilers if you already have not.
sudo apt install build-essentialCompile the program with g++ /path/to/filename.cpp -o /path/to/output (note that gcc may not work with programs written in C++. You would need g++).
Then run the program with /path/to/output.
Your code worked for me. I saved your code in the file new.cpp, and compiled it to an executable named output.
[archisman@home-pc ~]$ g++ new.cpp -o output
[archisman@home-pc ~]$ ./output
C++