Ch 15 - C++

Pataasin ang iyong marka sa homework at exams ngayon gamit ang Quizwiz!

The __ destructor is called before the __ destructor

derived, base

Multiple inheritance is when a __ class has __ base classes

derived, two or more

The compiler performs __on virtual functions

dynamic binding

__ members of a base class are never accessible to a derived class

private

In the following statement which is the derived class? class Car: protected Vehicle

Car

In an inheritance situation, the new class that you create from an existing class is known as the

a and c (derived class, child class)

The base class access specification determines how __ members in the base class may be accessed by derived classes

a,b,c (private, public, protected

The base class's __ affects the way its members are inherited by the derived class

access specification

Multiple inheritance opens the opportunity for a derived class to have __ members

ambiguous

In the following statement, what is being protected? class car: protected vehicle

base class members

The __ constructor is called before the __ constructor

base, derived

__ allows us to create new classes based on existing classes

inheritance

__ is commonly used to extend a class, or to give it additional capabilities

inheritance

When you derive a class from an existing class, you __ add new data and functions

may

Polymorphism is when __ in a class hierarchy perform differently, depending upon which object performs the call

member functions

When a derived class has two or more base classes, the situation is known as

multiple inheritance

Arguments are passed to the base class destructor function by the __ class a __ function

none of these ( derived, constructor; derived, destructor;base,constructor; base,destructor)

The following statement allows the __ members of the Car class to access __ members of the Vehicle class. class Car: private Vehicle

none of these (private, private; public, private; protected, private; public, protected)

A virtual function is a member function that expects to be __ in a derived class

overridden

__ to a base class may be assigned the address of a derived class object

pointers

The term __ means the ability to take many forms

polymorphism

When member functions behave differently, depending upon which object performed the call, this is an example of __

polymorphism

Protected members of a base class are like __, but they may be accessed by derived classes

private members

When the compiler binds a member function call with the version of the function that resides in the same class as the call itself, this is considered __ binding

static

In the statement class car:public vehicle, which is the base class?

vehicle

A virtual function is declared by placing the keyword __ in front of the return type in the base class's function declaration

virtual

__ functions are dynamically bound by the compiler

virtual

A __ of a base class expects to be overridden in a derived class

virtual function


Kaugnay na mga set ng pag-aaral

Benchmark Adelante Grado 5 Unidad 3 Semana 2

View Set

Prep U's - Chapter 40 - Fluid, Electrolyte, and Acid-Base Balance

View Set

Macroeconomics in Context Chapter 7 Study Guide

View Set

and this is the story of how i died

View Set