When a private constructer is being inherited from one
class to another class and when the object is instantiated
is the space reserved for this private variable in the
memory??
Answer Posted / sillu nu oru c coder
When a constructor is made private, object of that class
can not be created. That is called as Abstract class.
constructors can not be inherited. Moreover, when this
class is inherited, the base class object can not be
created. So we can not create the derived class object
also.
the above ans is irrelevant to the current situation,
here the thing is, a constructor cannot b private coz there
is no use of .
but if a situation occurs as such in the given prob, yes the
space is reserved for that useless private constructor.
Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
hi, this is raju,iam studying b.tech 2nd year,iam want know about group1 and group2 details, and we can studying without going to any instutions? please help me.
write a program to find 2^n+1 ?
Why do we use polymorphism?
What is encapsulation selenium?
Prepare me a program for the animation of train
What polymorphism means?
hi all..i want to know oops concepts clearly can any1 explain??
What is the main purpose of inheritance law?
What is the benefit of oop?
Plese get me a perfect C++ program for railway/airway reservation with all details.
What is the real time example of encapsulation?
What is destructor give example?
What is difference between class and object with example?
What are the 3 pillars of oop?
Why multiple inheritance is not allowed?