Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Question 7. 7. (TCO 1) Examine the class definition. How many members does it co

ID: 3561000 • Letter: Q

Question

Question 7.7. (TCO 1) Examine the class definition. How many members does it contain?

class clockType
{
public:
void setTime(int, int, int);
void getTime() const;
void printTime() const;
bool equalTime(const clockType&) const;
private:
int hr;
int min;
int sec;
};
  (Points : 5)        7
       3
       4
       None of the above Question 8.8. (TCO 7) Which of the following declares a pure virtual function in an abstract C++ class? (Points : 5)        public void drive()
       public void drive() {}
       public drive();
       public void drive()=0; Question 9.9. (TCO 4) Which of the following class definitions makes the public members of the class aClass become the public members of the class bClass?(Points : 5)        class aClass: public bClass
{
//...
};
       class bClass: public aClass
{
//...
};
       class bClass: aClass
{
//...
};
       class aClass: bClass
{
//...
}; Question 10.10. (TCO 8) Data/information hiding and encapsulation improves construction and maintenance because: (Points : 5)        program bugs are isolated to a single class.
       programming to an interface makes the code more logical.
       Both A and B
       None of the above Question 11.11. (TCO 8) What are some of the characteristics of "self-documenting" code? (Points : 5)        Logical identifier names
       Value-added comments
       Straightforward algorithms
       All of the above
       None of the above Question 12.12. (TCO 9) Which of the following allow a programmer to reduce the complexity of an object-oriented program? (Points : 5)        Create each class in a separate file
       Combine multiple classes in a same file to allow easy access
       Using one file to combine all the code to allow easy access
       None of the above Question 7.7. (TCO 1) Examine the class definition. How many members does it contain?

class clockType
{
public:
void setTime(int, int, int);
void getTime() const;
void printTime() const;
bool equalTime(const clockType&) const;
private:
int hr;
int min;
int sec;
};
  (Points : 5)        7
       3
       4
       None of the above

Explanation / Answer

7.7 = 7

8.8 public void drive()=0;

9.9    class bClass: aClass

10.10 program bugs are isolated to a single class.

11.11 All of the above

12.12 Using one file to combine all the code to allow easy access

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote