Aspire's Library

A Place for Latest Exam wise Questions, Videos, Previous Year Papers,
Study Stuff for MCA Examinations - NIMCET
Aspire Study - Best NIMCET Coaching

🎯 Crack NIMCET with Aspire Study

🔹 India's Most Trusted MCA Coaching
💻 Live + Recorded Classes | 👨‍🏫 Expert Faculty
📝 All India Test Series | 🎯 Personal Mentorship

🥈 NIMCET AIR 2: Ayush Garg

🚀 Join Aspire Now

📂 Aspire Study Library


Question Id : 17561 | Context : UGC NET Computer Science August 2024 (Paper II)

What is the output of code given below :

#include<iostream.h>

using namespace std;


class Base {

public:

    Base(){

        cout<<"Base Const";

    }


    virtual ~Base(){

        cout<<"Base dest";

    }

};


class derived : public Base {

public:

    Derived(){

        cout<<"Derived Const";

    }


    ~Derived(){

        cout<<"Derived dest";

    }

};


int main()

{

    Base *b = new Derived();

    delete b;

    return 0;

}


Aspire Study Online Test Series,
Information About Examination,
Syllabus, Notification
and More.

Click Here to
View More

📲
Ask Your Question or Put Your Review.

loading...