nerdexam
Oracle

1Z0-815 · Question #63

What is the name of the Java concept that uses access modifiers to protect variables and hide them within a class?

The correct answer is A. Encapsulation. Using the private modifier is the main way that an object encapsulates itself and hide data from the outside world.

Applying Encapsulation

Question

What is the name of the Java concept that uses access modifiers to protect variables and hide them within a class?

Options

  • AEncapsulation
  • BInheritance
  • CAbstraction
  • DInstantiation
  • EPolymorphism

How the community answered

(24 responses)
  • A
    71% (17)
  • B
    17% (4)
  • C
    4% (1)
  • D
    8% (2)

Explanation

Using the private modifier is the main way that an object encapsulates itself and hide data from the outside world.

Topics

#encapsulation#access modifiers#OOP concepts#data hiding

Community Discussion

No community discussion yet for this question.

Full 1Z0-815 Practice