1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
|
package test;
public class { public static void main(String[] args) { staticFunction(); }
static StaticTest st = new StaticTest();
static { System.out.println("1"); }
{ System.out.println("2"); }
StaticTest() { System.out.println("3"); System.out.println("a=" + a + ",b=" + b); }
public static void staticFunction() { System.out.println("4"); }
int a = 110; static int b = 112; }
|
近期评论