Writing First C++ Program - Hello World Example
Writing First C++ Program - Hello World Example C++ is a widely used Object Oriented Programming language and is fairly easy to understand. Learning C++ programming can be simplified into: Writing your program in a text editor and saving it with correct extension( .CPP, .C , .CP ) Compiling your program using a compiler or online IDE Understanding the basic terminologies. The "Hello World" program is the first step towards learning any programming language and is also one of the simplest programs you will learn. All you have to do is display the message "Hello World" on the screen. Let us now look at the program: CPP 1 2 3 4 5 6 7 8 9 10 11 12 13 14 // C++ program to display "Hello World" // Header file for input output functions #include <iostream> using namespace std ; // Main() function: where the execution of program begins int main ( ) { // prints hello world cout << " Hello World " ; return 0 ;