Exam 13: Introduction to Classes

arrow
  • Select Tags
search iconSearch Question
flashcardsStudy Flashcards
  • Select Tags

When the body of a member function is defined inside a class declaration, it is said to be ________.

(Multiple Choice)
4.8/5
(78)

Assume that myCar is an instance of the Car class, and that the Car class has a member function named accelerate. Which of the following is a valid call to the accelerate member function?

(Multiple Choice)
5.0/5
(67)

If you do not declare a destructor function, the compiler will furnish one automatically.

(True/False)
4.9/5
(73)

Objects are created from abstract data types that encapsulate ________ and ________ together.

(Multiple Choice)
4.8/5
(83)

You must declare all data members of a class before you declare member functions.

(True/False)
4.9/5
(93)

This type of member function may be called only from a function that is a member of the same class.

(Multiple Choice)
4.8/5
(92)

A private member function is useful for tasks that are internal to the class, but is not directly called by statements outside the class.

(True/False)
4.9/5
(88)

When an object is defined without an argument list for its constructor, the compiler automatically calls the object's default constructor.

(True/False)
4.9/5
(76)

The process of object-oriented analysis can be viewed as the following steps:

(Multiple Choice)
4.8/5
(90)

Objects in an array are accessed with ________, just like any other data type in an array.

(Multiple Choice)
4.9/5
(72)

When a constructor function accepts no arguments, or does not have to accept arguments because of default arguments, it is called a(n)________.

(Multiple Choice)
4.8/5
(82)

Assuming that Rectangle is a class name, the statement: Assuming that Rectangle is a class name, the statement:

(Multiple Choice)
4.9/5
(78)

More than one destructor function may be defined for a class.

(True/False)
4.9/5
(71)

Whereas object-oriented programming centers on the object, procedural programming centers on functions.

(True/False)
4.9/5
(75)

Examples of access specifiers are the key words:

(Multiple Choice)
4.9/5
(85)

When you dereference an object pointer, use the ________.

(Multiple Choice)
4.8/5
(83)

The constructor function always has the same name as ________.

(Multiple Choice)
4.8/5
(72)

If a local variable and a global variable have the same name within the same program, the ________ resolution operator must be used.

(Multiple Choice)
4.8/5
(85)

This is used to protect important data.

(Multiple Choice)
4.9/5
(73)

What is the output of the following program? What is the output of the following program?

(Multiple Choice)
4.9/5
(97)
Showing 21 - 40 of 47
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)