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

You have one base class virtual function how will call that
function from derived class?

Answer Posted / narendra

class A
{
public:
virtual void fun()
{
cout<<"class A\n";
}
};
class B:public A
{
public:
virtual void fun()
{
cout<<"class B\n";
A::fun(); //calling base class virtual function.
}
};

Is This Answer Correct ?    4 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why is encapsulation used?

1005


What is polymorphism and why is it important?

1052


What is difference between abstraction and encapsulation?

1095


What is the example of polymorphism?

1140


What does and I oop mean?

1208


What is advantage of inheritance?

1183


What is multilevel inheritance?

1209


What is encapsulation selenium?

1023


What is for loop and its syntax?

1095


What does sksksk mean in text slang?

2130


What is a class oop?

1021


write knight tour problem which is present in datastructure

2665


Why do we use class in oops?

978


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?

2402


What is the advantage of oop over procedural language?

1095