java

Java finalize() method | Java 8

Java Object class has a method called finalize which is provide for garbage collector. Actually garbage collector (GC) cleans up objects from heap after certian time. We have a seperate…

Heap Memory in Java

This is created by JVM while its boostratp time. All class instances are created up on heap memory and memory management is governed by garbage collector (GC) . Heap memory…

Heap vs Stack memory in Java

Very first lets look at what is stack and heap and finally we can explain how Java JVM allocate memory in those two areas.  Stack Stack stores temporary variables created…