what is virtual function?
Answer Posted / vindhyachal kumar gupta
C++ virtual function is a member function of a class, whose
functionality can be over-ridden in its derived classes. The
whole function body can be replaced with a new set of
implementation in the derived class. The concept of c++
virtual functions is different from C++ Function overloading.
C++ Virtual Function - Properties:
C++ virtual function is,
* A member function of a class
* Declared with virtual keyword
* Usually has a different functionality in the derived class
* A function call is resolved at run-time
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
why reinterpret cast is considered dangerous?
write a program that takes input in digits and display the result in words from 1 to 1000
Which language is pure oop?
Why is it so that we can have virtual constructors but we cannot have virtual destructors?
Which is not an object oriented programming language?
What is polymorphism give a real life example?
What is overriding vs overloading?
What is advantage of inheritance?
What is the main feature of oop?
Why do we use oop?
Is oop better than procedural?
Why interface is used?
What is the significance of classes in oop?
What is inheritance in simple words?
Can abstract class have normal methods?