C++ program to print hello world

Write a program to print the hello world program in c++. This is a basic set of the program in C++ programming language for beginners. The display screen is usually the standard output device. The ostream class is represented by the C++ cout statement. It’s used to generate output for the standard output device, which is often a display screen.

int main() 
std::cout << "Hello world";
return 0;



Hello world

Difference between cin and cout in c++

cin is an input stream object that accepts input from files, consoles, and other input streams. cout is an output stream object that is used to display output. cin is an input statement, whereas cout is an output statement.

Return statement and how to impletement in c++ program

Returns control to the caller function once a function has completed its execution (or to the operating system if you transfer control from the main function). The calling function continues execution at the place where the call was made.