Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

cin c++

#include <iostream>
using namespace std;

int main() {
 	int n1, n2;
  	float f1;
  	char c1;
    
    cout<<"Enter two integers, a float and a char: ";
    cin>>n1>>n2>>f1>>c1;	//multiple input in single line
    
    cout<<"Check: "<<n1<<n2<<f1<<c1<<endl;
	return 0;
}
Source by www.geeksforgeeks.org #
 
PREVIOUS NEXT
Tagged: #cin
ADD COMMENT
Topic
Name
3+1 =