In this post, we’ll see the use of static keyword on variable, method, class and blocks. How it differ from normal object creation.
The static modifier is used to create variables and methods that will existindependently of any instances created for the class.
All static members exist before you ever make a new instance of a class, and there will be only one copy of a static member regardless of the number of instances of that class.
In other words, all instances of a given class share the same value for any given staticvariable.
Click here to read more