Exam 10: Classes and Data Abstraction
Exam 1: An Overview of Computers and Programming Languages40 Questions
Exam 2: Basic Elements of C++50 Questions
Exam 3: Inputoutput40 Questions
Exam 4: Control Structures I Selection40 Questions
Exam 5: Control Structures II Repetition40 Questions
Exam 6: User-Defined Function41 Questions
Exam 7: Namespaces, the Class String, and User-Defined Simple Data Types40 Questions
Exam 8: Arrays40 Questions
Exam 9: Records Structs40 Questions
Exam 10: Classes and Data Abstraction43 Questions
Exam 11: Inheritance and Composition41 Questions
Exam 12: Pointers, Classes, Virtual Functions, and Abstract Classes43 Questions
Exam 13: Overloading and Templates41 Questions
Exam 14: Exception Handling42 Questions
Exam 15: Recursion41 Questions
Exam 16: Searching and Sorting46 Questions
Exam 17: Linked Lists41 Questions
Exam 18: Stacks and Queues42 Questions
Select questions type
If an object is declared in the definition of a member function of the class, then the object can access both the public and private members of the class.
Free
(True/False)
4.9/5
(32)
Correct Answer:
True
A(n) ____________________ contains the definitions of the functions to implement the operations of an object.
Free
(Short Answer)
4.8/5
(36)
Correct Answer:
implementation file
In C++, the scope resolution operator is ____.
Free
(Multiple Choice)
4.8/5
(49)
Correct Answer:
B
If the heading of a member function of a class ends with the word const, then the function member cannot modify the private member variables, but it can modify the public member variables.
(True/False)
4.9/5
(44)
A(n) ____________________ is a statement specifying the condition(s) that must be true before the function is called.
(Short Answer)
4.8/5
(45)
In C++, class is a reserved word and it defines only a data type.
(True/False)
4.9/5
(35)
Non-static member variables of a class are called the ____________________ variables of the class.
(Short Answer)
4.8/5
(40)
-Consider the UML class diagram shown in the accompanying figure. According to the UML class diagram, how many private members are in the class?

(Multiple Choice)
4.9/5
(39)
As parameters to a function, class objects can be passed by reference only.
(True/False)
4.9/5
(36)
-Consider the accompanying class definition, and the declaration: rectangleType bigRect;
Which of the following statements is correct?

(Multiple Choice)
4.7/5
(41)
A destructor has the character ____, followed by the name of the class.
(Multiple Choice)
4.9/5
(37)
-Consider the accompanying class and member functions definitions. How many constructors are present in the class definition?

(Multiple Choice)
4.8/5
(33)
You can use arithmetic operators to perform arithmetic operations on class objects.
(True/False)
4.8/5
(34)
A class and its members can be described graphically using a notation known as the ____ notation.
(Multiple Choice)
4.8/5
(37)
To guarantee that the member variables of a class are initialized, you use ____.
(Multiple Choice)
4.7/5
(40)
A class object can be ____. That is, it is created each time the control reaches its declaration, and destroyed when the control exits the surrounding block.
(Multiple Choice)
4.8/5
(36)
Showing 1 - 20 of 43
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)