source file can't have more than one public class

后端 未结 6 1265
野的像风
野的像风 2021-01-12 10:02

we can declare only one public file in a source file and file name must match the public class name

is there any reason to this restriction....

6条回答
  •  迷失自我
    2021-01-12 10:32

    simply remember only that class would be public which has the main other files dont be public

提交回复
热议问题