Given a method in a protected class, what access modifier do you use to restrict access to that method to only the other members of the same class?

  1. final

  2. static

  3. private

  4. protected


Correct Option: C
Explanation:

The private access modifier limits access to members of the same class.

More quiz related to this question.

Find more quizzes: