What are the rules to name a Java file without public class defined in it?
A8. Everyone knows one Java file only can contain one public class, and the file must be named as the name of the public class name. But how about Java file with no public class? No restrictions on name of Java file without public class defined. If you have a class with a main, you’d better name the file with that class name for your own convenience. However, this is not required. Test this out!