This time i have got a simple but confusing(for me) question.
I know that in a file only one public class is allowed ,the question is why they have put such a rule?
suppose i have got three "public" classes written in 3 diff files(say j1.java,j2.java,j3.java)When i compile j1,j2,j3 indivdually i will get three class files j1.class, j2.class and j3.class
now i am putting these three java files in a single file say j.java ,and when i compile j.java, still you will get those j1.class, j2.class and j3.class(+j.java). what is the difference between these classes and the above classes?
i refered all the java sites that i know,but all just say that ,only one public class/file because sun desiged it that way..
ooh man !!somebody teach me the fundamentals :(