PrepZone Logo
PrepZone
Back to Java

Java · Medium

What is garbage collection? How does it work?

JavaMemory & JVMJVM

Answer preview

Garbage Collection is the JVM's automatic memory management — it identifies unreachable objects on the heap and reclaims their memory without programmer intervention.…