What is responsiblity of Garbage Collector ?

Garbage collector frees the memory occupied by the unreachable objects during the java program by deleting these unreachable objects. It ensures that the available memory will be used efficiently, but does not guarantee that there will be sufficient memory for the program to run. The GC ( Garbage collector) runs on a dameon thread. A dameon thread runs behind the application. It is started by JVM. The thread stops when all non-dameon threads stop.

core java 12

FOLLOW US ON LinkedIn



Explore Tutu'rself