adplus-dvertising
frame-decoration

Question

What is the output of this program?
    #include <iostream>
    using namespace std;
    ostream & operator<<(ostream & i, int n)
    {
        return i;
    }
    int main()
    {
        cout << 5 << endl;
        cin.get();
        return 0;
    }

a.

5

b.

6

c.

error

d.

runtime error

Answer: (c).error

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. What is the output of this program?