Question 6
Back to Exercise
How is data hiding related to encapsulation?
- A They are unrelated
- B Data hiding (making fields private) is one part of encapsulation, which also bundles behaviour with the data Correct
- C Encapsulation is part of data hiding
- D Data hiding means deleting data
Correct Answer: Option B
Encapsulation is the broader idea.
Discussion & Comments 0
Share your method, a shortcut, or ask about a step you didn't follow.
No comments yet. Be the first to share your solution!