If I try compiling my C++ source file by the following command:
g++ a.cpp
it outputs:
The program 'g++' can be found in the following packages:
* g++
* pentium builder
try:
sudo apt-get intsall <<a>selected package>
However, if I run the suggested command (sudo apt-get install g++), it shows that everything is already installed.
So, basically, how do I compile a simple C++ program in Ubuntu 12.04?


which g++? This sounds like g++ is not in your path. – Chris Betti Dec 6 '12 at 14:16build-essential?sudo apt-get install build-essential. – Chris Betti Dec 6 '12 at 14:26