what is virtual function?
Answer Posted / dev malhotra
virtual function is defined as virtual is a keyword which is used when one function or method is used in both base class and drived class at a time then, during compile time compiler cannot distinguish that which one compile or run first.
then to distinguish that problem the programmer use special keyword in base class or in derived class that is known as "VIRTUAL" keyword.
Due to this keyword the compiler always compiles the assigned virtual keyword method or function and this is called as virtual function.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Write a c++ program to display pass and fail for three student using static member function
What is encapsulation in oops?
What is abstraction example?
program for insertion ,deletion,sorting in double link list
is there any choice in opting subjects like 4 out of 7
Why is polymorphism important in oop?
What is polymorphism explain its types?
What are the benefits of oop?
What are the 5 oop principles?
Whats oop mean?
What is the difference between a mixin and inheritance?
What is the use of oops?
What is use of overloading?
Why do while loop is used?
How to improve object oriented design skills?