I wrote the following on a notepad and save it as hello_world.cpp in the following folder: C:\cplusplus
#include <iostream>
main(int argc, char* argv[])
{
std::cout << "Hello World\n";
return 0;
}
I brought up cmd.exe and executed the following code to compile the cpp file.
C:\Program Files (x86)\CodeBlocks\MinGW\bin>g++.exe C:/cplusplus/hello_world.cpp
-o hello_world.o
However, I got the following error message:
g++.exe: error: CreateProcess: No such file or directory
I wonder if someone could point out what I did wrong.
Thank you!