1.

What is the output of this program?
#include <iostream>
using namespace std;
class First
{
public:
First(int num1 )
{
cout << num1 < }
};
class Second: public First
{
public:
Second(int num1, double num2)
: First(num1)
{
cout << num2 < }
};
class Third: public Second
{
public:
Third(int num1, double num2, char ch)
: Second(num1, num2)
{
cout < }
};
int main()
{
Third object(6, 5.35, 'I');
return 0;
}

A. 6 I 5.35
B. 6 3.5
C. I 5.3 6
D. I 6
E. 6 5.35 I
Answer» F.


Discussion

No Comment Found

Related MCQs