//Example 2
of input and output
#include <iostream>
using namespace std;
int main()
{
int i, j;
double x, y;
cin >> i >> j >> x >> y;
cout << “First output “ << endl;
cout << i << ',' << j << ',' << x
<< ',' << y << endl;
cin >> x >> y >> i >> j;
cout << “Second output” << endl;
cout << i << ',' << j << ',' << x
<< ',' << y << endl;
return 0;
}
//Input stream is:
1 2
3.4 5
2 3 3.4 7