This tutorial will help to read about Java important differences everyone must know. Based on my prior experience, this gets asked most of the time in interviews, irrespective of the number of years.
It is a java keyword used as a non-access modifier with Classes, attributes and methods.
After making class as final will not allow us to inherit the class.
Method as final will not allow us override in child class.
Making any variable as final will not allow us to override the value.
Finally block is used to execute for closing an open connections.
Note:
Every time an object is garbage collected, the finalize() method is called.
We can request the garbage collector to run using the System.gc() method.
List: List allows duplicate values. It allows multiple null values. It maintain insertion order.
Set: Set doesn’t allow duplicate value. Set allows only one null value. It doesn’t maintain any insertion order. Set elements can be iterate using keyset() and entryset()
Map: Map allows only one null key and multiple null values. Map maintain insertion order. Element need to convert into set to iterate.
Specialist Master (Architect) with a passion for cutting-edge technologies like AEM (Adobe Experience Manager) and a proven track record of delivering high-quality software solutions.
📝 Blogs
javadoubts.com © All rights reserved