Question: what is gc in java?
Answer: Java garbage collection is the process by which Java programs perform automatic memory management. Java programs compile to bytecode that can be run on a Java Virtual Machine, or JVM for short. ... The garbage collector finds these unused objects and deletes them to free up memory.