摘要:
Unlike methods, a constructor cannot be abstract, static, final, native or synchronized. 1. A constructor is not inherited, so there is no need to dec... 阅读全文
摘要:
一个Java文件中可以包含多个类。如果有public类,则文件名必须和public类一样。例如: 1 class Pie { 2 void f(){ 3 System.out.println("Pie.f()"); 4 } 5 } 6 7 class Cake { 8 ... 阅读全文