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 virtual function in c++

Answer Posted / achal

the concept of vitual function comes when inheritance is at
work. If the overriden function is not made virtual in base
class , then pointer of derived class will call the funtion
in base class(instead it should have called the one from
derived class.)
this is why we make the function in base as virtual.

Is This Answer Correct ?    37 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between a constructor and a destructor?

1268


What is overloading and its types?

1183


Why can't we have instance(stack) of a class as a member of the same class like eg.Class A{A obj;} as we can have self refential pointer

2158


What is overriding vs overloading?

1069


What are different oops concepts?

1066


What is abstraction oop?

1103


What is abstract class in oops?

1026


Describe these concepts: Polymorphism, Inheritance and Abstraction.

1201


What is polymorphism what are the different types of polymorphism?

1014


Hi friends I have experience of 6 months in website design and maintanence. Now i am looking for other IT jobs.. to switch platform. please post any interview you know in chennai.

2198


write a program that takes input in digits and display the result in words from 1 to 1000

2432


Can a varargs method be overloaded?

1114


What is variable example?

1046


to find out the minimum of two integer number of two different classes using friend function

2147


Explain the concepts involved in Object Oriented programming.

1249