What is the output of the program?

What is the output of the program? #include using namespace std;
class BaseC
{ int i; public: BaseC() { i=?1;} BaseC(int i) { i=i; } void seti(int a) { i = a; }; void Print() { cout << i; } }; int main() { BaseC *o = new BaseC(); o?>seti(10); o?>Print(); }
A. It prints: 10
B. It prints: ?1
C. It prints: 0
D. Compilation error

Download Printable PDF. VALID exam to help you PASS.

Posted in: CPA

Leave a Reply

Your email address will not be published. Required fields are marked *


The reCAPTCHA verification period has expired. Please reload the page.