What is the difference between the cout and cin iostream
objects?

Answer Posted / mukta b

• Cin : Represented by insertion operator >>
Cout : Represented by extraction operator <<

• cin : is an object of input streams like consoles, files, etc.
Cout : is an object of output streams that's used to show outputs.

• cin : is an input statement
cout : is an output statement

Example :
#include<iostream.h>
#include<conio.h>
void main()
{
int a;
cout<<"Enter value for a: "; //taking value of a
cin>>a; //inputing value
cout<<"A = "<<a; //outputing value
getch();
}

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the important features of vc++?

596


Do I need microsoft visual c++?

565


How can we use cmutex?

558


What is difference between c++ and visual c++?

548


What is microsoft visual c++ runtime library error?

553






What is microsoft visual c++ redistributable and do I need it?

537


Is microsoft visual c++ important?

630


What is iunknown? Explain some of commonly used methods provided by iunknown.

605


What is vc++ programming?

678


What is the use of microsoft visual c++ 2015 redistributable?

519


How you build a project using Developer Studio?

1753


What is iunknown?

548


Is it safe to uninstall microsoft visual c++ 2008 redistributable?

563


What is microsoft visual c++ 2015 redistributable package x64?

555


What is visual c++ 2008 redistributable x64?

551