The JAVA field (which is located in the Object in the heap) is default initialized as 0, false, and null.
A a = new A(); // equal
A a; // a is pointer/ref in the stack. (In stack the integer value take the random value)
a = new A(); // new A() is the Object in the heap. (In heap the integer value will be initialized as 0)