0
what is the difference between final and static keywords
3 Respostas
+ 1
static means that the element can be used without instanciating an object of the class first.
final means that the value of the element cannot be modified, it's how you declare constants. If that element is a method, you cannot override it.
0
Final means you cannot create subclasses of that class. Static variable of a class means there is only one variable shared btw all the objects of that class
0
static is shared throughout classes and sub classes and its can be changed, where final can be used throughout classes and subclasses and cannot be changed