Pages - Menu

Hello world example of C++

Hello world example and explaination of it in C++

C++ is best language for new learners and also for advanced programmers. This language is close to the hardware and you can say it is low level as well as high level language.

Low level languages are closer to the hardware. Everyone has to start somewhere so, here is hello world application.

#include <iostream>
using namespace std;
int main()
{
    cout << "Welcome to C++" << endl;
    system("pause");
}

Above example shows Welcome to C++ message to the screen. system("pause") is totally optional. It is to hold screen and wait for user to press some key.