Before getting into any theory, let's look at a simple C++ program. We will start by entering, compiling, and running the following program.
You will follow these steps.Code:/* Program #1 - A first C++ program. Enter this program, then compile and run it. */ #include <iostream> using namespace std; // main() is where program execution begins. int main() { cout << "This is my first C++ program."; return 0; }
1. Enter the program.
2. Compile the program.
3. Execute the program.
Before beginning, it is necessary to fedine two terms. The first is source code. Source code is the version of your program that humans can read. :P The preceding listing is and example of source code. The executable version of your program is called object code or executable code. Objeect code is created by the compiler when it compiles your pgoram.