What is garbage collection in Java, and how can it be used ?
Answer Posted / sachin deshmukh
In java doesn't allow memory leakage,Garbage collector
automatically deallocates memory.It deallocates memory of
objects that no longer has any references i.e. references
count is zero.
| Is This Answer Correct ? | 4 Yes | 5 No |
Post New Answer View All Answers
Mention a package that is used for linked list class in java.
What do you mean by garbage collection used in java?
How to make a write-only class in java?
What will be the output of round(3.7) and ceil(3.7)?
Is boolean a wrapper class in java?
Why does java have two ways to create child threads?
Why collection doesn’t extend cloneable and serializable interfaces?
What are anonymous inner classes?
What is difference between float and double?
How can we make sure main() is the last thread to finish in java program?
What is an object class?
Can we sort array in java?
Give the hierarchy of inputstream and outputstream classes.
How does queue work in java?
Is empty in java?