Java OCA OCP Practice Question 414

Question

Which statement is true?

Choose all that apply.

  • A. Cohesion is the OO principle most closely associated with hiding implementation details
  • B. Cohesion is the OO principle most closely associated with making sure that classes know about other classes only through their APIs
  • C. Cohesion is the OO principle most closely associated with making sure that a class is designed with a single well-focused purpose
  • D. Cohesion is the OO principle most closely associated with allowing a single object to be seen as having many types


C is correct.

Note

A, B, and D are incorrect.

Option A refers to encapsulation, B refers to coupling, and D refers to polymorphism.




PreviousNext

Related