<<< Inside a Constructor | Index | Multiple Constructors >>> |
The classes get a default constructor provided by Java.
The default constructor initializes
all primitive numeric attributes to 0
all object attributes to null.
Often there is no reason to code default constructor because it would have the same functionality as the compiler-provided constructor.
On the other hand, many programmers prefer to code it for documentation purposes anyway.
<<< Inside a Constructor | Index | Multiple Constructors >>> |