What is the Static identifier in oops concepts ?
Static identifier
1235
07-Jul-2018
Prakash nidhi Verma
07-Jul-2018static identifier :
The static identifier is used for only one times initialization and the value access during the life time of the program /application. A separate memory is allocated for static variables. This value can be used between function calls. The default value of an uninitialized static variable is zero.
A static identifier of program execution depends on its default value of a uninitialized static identifier which is zero.
class StaticEx{static int initializeValue;
static{
initializeValue = 5;
System.out.println("I");
}
{
initializeValue = 50;
System.out.println("II");
}
StaticEx(){
initializeValue = 500;
System.out.println("II");
}
}