How to get input from the user in a C++ program

To Get Input From The User:



Syntax:
The syntax used to get input from the user is cin>>.

Program:

#include < iostream >
using namespace std;
int main()
{
int a;
cin >> a;

cout << "The value = " << a << endl;
return 0;
}

Comments

Popular posts from this blog

How to display the output in C++