Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

c++ add input in

cin >> variable;

// sample 1
int x;
cout << "x: ";
cin >> x;
cout << x << endl;

//sample 2
int num;
for (int i = 0; i < 10;  i++){
	cout << "Give a number: ";
    cin >> num;
}
 
PREVIOUS NEXT
Tagged: #add #input
ADD COMMENT
Topic
Name
2+2 =