What is garbage collection in Java, and how can it be used ?
Answer Posted / syed sikandar bakht
when an object in memory is no longer refered by a variable,
the garbage collector automatically move it to garbage
collection.
instead of calling destructor JVM do it automatically, as we
use destructor in c++ to destroy the object.
Is This Answer Correct ? | 20 Yes | 6 No |
Post New Answer View All Answers
How is it possible in java programming for two string objects with identical values not to be equal under the == operator?
What is the transient keyword?
What is variable length arguments in java?
What are triggers in DB? Explain their types. How do they work?
What are java packages?
How to print nodes of a Binary tree?
What is use of valueof () in java?
How can you say java is object oriented?
What is api data?
Does constructor be static?
What is integers and example?
What is the final keyword?
What is annotation in java?
What is comparator in java?
What is main string [] args?