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

What is object slicing and how can we prevent it?

Answer Posted / vikas

Object slicing occurs when we assign an instance of the
subclass to a variable of type base class.

http://www.cppquestions.com/viewtopic.php?f=17&t=49

Is This Answer Correct ?    12 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why main function is special in c++?

1117


Write a program in c++ to print the numbers from n to n2 except 5 and its multiples

2476


What is the basic structure of a c++ program?

1143


Why c++ is faster than java?

1053


How can you link a c++ program to c functions?

1101


What are stacks? Give an example where they are useful.

1044


Is std :: string immutable?

1034


What is #include sstream?

1062


What are destructors?

996


What's the best free c++ profiler for windows?

1078


Is it possible to provide default values while overloading a binary operator?

1266


How do you clear a buffer in c++?

958


What is a manipulator in c++?

1231


which operator is used for performing an exponential operation a) > b) ^ c) none

1059


List the advantages of inheritance.

1123