CPP Hello World Program Example

  1. Home
  2. Tutorials
  3. CPP
  4. CPP Programs
  5. Output Statement
  6. Program

Source Code:

#include <iostream>
// standard namespace
using namespace std;
int main(int argc, char** argv) {
    
    // output statement
    cout<<"Hello World"; //terminated by semicolon
    
    /*
    We can write multiple
    cout (output) statements
    to print text on the 
    console device (monitor)
    */

    
    return 0;
}

Output:

hello world program in C++

Working:

This program is compiled using Dev-C++ IDE. This is normally considered as first program for developer who start learning C++. In this program we have write down a single cout (output) statement that will print Hello World on the screen

Comments
Login to TRACK of Comments.