What is the difference between a public and a non-public class | Eklavya Online

What is the difference between a public and a non-public class

A public class may be accessed outside of its package.

A non-public class may not be accessed outside of its package.