C++20 sections · 1024 units
Open in Course

Quiz: Method Overriding

Knowledge check

Check Your Understanding

What happens when a derived class defines a function with the same name and signature as a base class function?

  1. A.Both functions are called in sequence
  2. B.Compilation error - duplicate function names
  3. C.The derived class version overrides the base class version
  4. D.The base class version is called instead
Start the roadmap to answer the quizzes and solve the challenges