private means that it cannot be accessed from outside of the class. The scope is a class field. It can be accessed by the entire class. There are many reasons why you would want to control access to a variable from being changed or even read from outside the class it is in.
posted 3 years ago
Consider a public class Course which has a private reference variable Student:
Now suppose a public class School where a method instantiates Course. When we look at Course from the class School, we will not be able to see the Student variable.