Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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 / sanjay makwana, puna

Private Constructor is not inherited.
When private member varible is not inherited but the size is
occupid in dervied class object.

e.g.
#include <iostream.h>
class A
{
int x;
int y;
};

class B : private A
{
};

int main()
{
cout << sizeof(B);
}

output :
8

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is encapsulation in simple terms?

1044


Can a destructor be called directly?

1077


What is overloading in oop?

1015


What is destructor in oop?

1037


Write a program to sort the number with different sorts in one program ??

2379


Can destructor be overloaded?

1039


write a program to find 2^n+1 ?

2076


What are the types of abstraction?

1080


just right the logic of it 1--> If few people are electing then every time ur candidate should win 2--> arrange books in box, if box carry weight == books weight then take another box..... find the no of box required.

6938


String = "C++ is an object oriented programming language.An imp feature of oops is classes and objects".Write a pgm to count the repeated words from this scenario?

2399


i am getting an of the type can not convert int to int *. to overcome this problem what we should do?

2320


What does enum stand for?

1128


What is class in oop with example?

1107


Why do we use encapsulation in oops?

1046


What is for loop and its syntax?

1088