What is garbage collection in Java, and how can it be used ?

Answer Posted / devarathnam c,kotagudibanda(po

Hi...
GarbageCollector: Whenever an object is no longer used in
the program at that time the garbage collector reclaims the
memory of an object.It is controlled by the JVM ,The JVM
runs periadically by using "mark" and "sweep"algorithms.
Instead of "destructor" in c++ , java supports garbage
collector.

Is This Answer Correct ?    84 Yes 21 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many techniques can be employed to create a string object?

551


What is t type java?

622


What do you mean by buffering?

550


What methodology can be utilized to link to a database?

504


Why do we need singleton class?

547






Explain 5 io best practices?

592


What is difference between final and finally in java?

580


What is join () in java?

528


Define canvas?

564


What is incompatible types in java?

533


What is number data type?

531


What is the meaning of find and replace?

524


What do you mean by an interface in java?

570


What is the use of math abs in java?

547


How do you override a private method in java?

498