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...



C++ Interview Questions
Questions Answers Views Company eMail

How to reduce a final size of executable?

3 15799

Give 2 examples of a code optimization?

4 15013

if 4-5 year old brother is standing on d roof with me and watching d moon, suddenly moon coverd by cloud then how will i explain d hiding of moon to my brother.

MBT,

8 12701

write a piece of c++ code which allocate memory to the 50 object of type CObj

2 7472

what is object slicing?

L&T, Wipro,

9 50329

tell me about yourself ?i want answer for frehers with various exasmples?

HCL,

2 7266

who is the founder of c++?

Hexaware, ONGC,

15 39047

//what is wrong with the programme?? #include template class dd { first i; public: void set(); void print(); }; void dd< first>:: set() { cin>>i; } void dd< first>::print() { cout<<"\n"<g; g.set(); g.print(); }

1 4412

what is pulse code modulation?

Wipro,

2 10584

what is an instance of a class

5 8910

wrong statement about c++ a)code removably b)encapsulation of data and code c)program easy maintenance d)program runs faster

11 24276

const char * char * const What is the differnce between the above two?

TCS,

11 21033

What is a class?

Infosys, TCS, Thylak,

32 33265

What is an object?

HCL,

14 17848

What is the difference between an object and a class?

3 7310


Un-Answered Questions { C++ }

Question In a class, there is a reference or pointer of an object of another class embedded, and the memory is either allocated or assigned to the new object created for this class. In the constructor, parameters are passed to initialize the data members and the embedded object reference to get inialized. What measures or design change should be advised for proper destruction and avioding memory leaks, getting pointers dangling for the embedded object memory allocation? Please suggest. Question Submitted By :: Sunil Kumar I also faced this Question!! Rank Answer Posted By Re: In a class, there is a reference or pointer of an object of another class embedded, and the memory is either allocated or assigned to the new object created for this class. In the constructor, parameters are passed to initialize the data members and the embedded object reference to get inialized. What measures or design change should be advised for proper destruction and avioding memory leaks, getting pointers dangling for the embedded object memory allocation? Please suggest. Answer # 1 use copy constructors 0 Shanthila There is something to be taken care in destructor, in copy constructor, suppose the memory is assigned to the embedded member object pointer with the parameter passed value, but if some other objects of different class also are pointing to this memory, then if some one deletes the object then this class member pointer object will become dangling, or if the object is not deleted properly then there will be memory leak. Please suggest the design change required to handle or avoid this situation

2131


Is std :: string immutable?

1042


What is the use of object in c++?

1105


There is a base class sub, with a member function fnsub(). There are two classes super1 and super2 which are sub classes of the base class sub.if and pointer object is created of the class sub which points to any of the two classes super1 and super2, if fnsub() is called which one will be inoked?

995


Explain the difference between method overriding and method overloading in C++?

1052


What is an incomplete type in c++?

1282


what are the types of Member Functions?

1131


What is setfill c++?

1159


Why do we need function?

1055


Differentiate between a template class and class template in c++?

1101


What is c++ and its uses?

1229


What is encapsulation oop?

1042


State what is encapsulation and friend function?

1267


What is the use of ::(scope resolution operator)?

1076


Explain the difference between overloading and overriding?

1143