0
What is static in java
ee
2 Respostas
+ 1
When there are 2 Objects instantiated on the same class, they can access a global variable of that class, and provide a different value same global variable because they are 2 different objects, and this is the only way to access a (none private) global variable outside the implementing class.
When a static global variable is declared, it's call "Class Variable", and it can be called either instantiating objects of that class or simply calling that variable directly with the syntax <ClassName>.<VariableName>, the last value provided is the the value that the variable will hold. Good luck Bismillah.