How can we call the garbage collector?

How can we call the garbage collector?

  • Garbage collector is automatically invoked when the program is being run. It can be also called by calling gc() method of Runtime class or System class in Java

 

Leave a Reply