 When the class is declared as public, it is accessible to other classes defined in the same package as well as those defined in other packages.This is the most commonly used specifier for classes.However, a class itself cannot be declared as private.