Answer Posted / uv
As far as I know,it is not required to call the garbage
collector.
It automatically and periodically removes the unused
objects by an algorithm known as "Mark and Sweep".
However, if we intentionally want to call it then the above
suggestions are perfect.
Anyone who feels that it is incorrect, please feel free to
correct me.
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
What is final?
What is an exception in java?
What is the maximum size of list in java?
List some oops concepts in java?
Program to Find the second largest element in an array.
What are the types of relation?
What is a boolean flag in java?
What ide should I use for java?
How do I enable java in safari?
Why does java not support pointers?
What are local variables?
Explain some best practices you would apply while using collection in java?
How much is a java license?
What are conditionals and its types?
What is polymorphism and what are the types of it?