Why Integer Class in Final in Java ?

Integer class is a wrapper for int. If it is not marked final, then any other class can extend it and modify the behavior of Integer operations. To avoid this Integer wrapper class is marked as final.



You May Interest

What is a CAS Operation in Java ?

What are the Differences Between Collection and Collections in Ja ...

How Can Be Read Data From a Form in a JSP ?

How Will You Pass Information From One JSP to Another JSP ?

What is the Importance of hashCode and equals Methods in Java ?