Declaring a class-typed variable creates no object: the variable stays without a value until it is assigned one created with New.
1A new object is reserved with its attributes without a value.
2The constructor runs with inicial = 10, and This.valor receives 10.
3The reference to the object is stored in the variable.
Figure 9.3-1.What happens when NewContador(10) is evaluated.
The variable pasos starts empty. An object with the attribute valor is reserved, the constructor gives it 10 and finally pasos receives the reference to the object.
If the class inherits, the superclass part is built before the constructor body. When the superclass constructor needs arguments, the first statement must be Super.Constructor(…).
In short
NewClass(…) creates an object and runs its constructor.
There is at most one constructor; without it, an implicit one that initializes nothing.
Declaring a class variable does not create the object.