The Java Platform Java Runtime Environment Data Types![]() Objectives![]() Data Types![]() Variable Types![]() Variable Default value![]() Declaration and Initialization![]() Casting![]() Operators![]() OOP Central Concepts Control Statemets Methods Arrays Classes and Objects Inheritance Constructor Interface Packages & Access Modifiers Java Collections Framework | Variable Default valueOne Java peculiarity is the default initial values of these three types of variables. Both class variables and instance variables default to certain values: Table 5. Default values for Class and Instance Variables
Local variables do not have default values, and must be initialised. |