Q:

Why virtual functions cannot be static in C++?

0

Why virtual functions cannot be static in C++?

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

Answer:

Virtual functions are invoked when you have a pointer/reference to an instance of a class. Static functions aren’t tied to a particular instance, they’re tied to a class

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

C++ Interview Questions For Experienced

This question belongs to these collections

Similar questions


need a help?


find thousands of online teachers now
What is the “mutable” keyword in C++?... >>
<< What is the Diamond problem? How can we get around...