原题是这样的:
Create a class without a constructor, and then create an object of that class in main( ) to verify that the default constructor is automatically synthesized.
怎样才能知道一个类的默认的构造函数(也就是不定义)是有运行的呢?
...全文
764打赏收藏
一个奇怪的问题,来自 Thinking in Java 3rd
原题是这样的: Create a class without a constructor, and then create an object of that class in main( ) to verify that the default constructor is automatically synthesized. 怎样才能知道一个类的默认的构造函数(也就是不定义)是有运行的呢?