Advertisements
Advertisements
Question
What is meant by private visibility of a method?
Short Answer
Solution
Private methods in Java are only accessible within the class where they are declared. Private methods are contained in their respective classes, ensuring that they are not used elsewhere in the code. This offers them the confidence to adjust or modify the secret approach without negative consequences.
shaalaa.com
Is there an error in this question or solution?