+ 2
Why does java file name must be same as public class name?
2 odpowiedzi
+ 2
Programmer Raja
Generally the file name is keep same so that when one or more Java classes are made in one file then after compilation so many. Java files are generated and by this reason it's so hard to find the entry point and the main function for compiler so same name is kept so it directly have access to that entry point
https://netjs.blogspot.com/2015/04/why-file-name-and-class-name-same-in-java.html?m=1
https://www.quora.com/Why-does-java-file-name-must-be-same-as-public-class-name