Start networking and exchanging professional insights

Register now or log in to join your professional community.

Follow

Which of the following jobs are NOT performed by Garbage Collector?

  1. Freeing memory on the stack.
  2. Avoiding memory leaks.
  3. Freeing memory occupied by unreferenced objects.
  4. Closing unclosed database collections.
  5. Closing unclosed files.

 

A. 1,2,3 B. 3,5 C. 1,4,5 D. 3,4

user-image
Question added by Mohannad Bakbouk , Full Stack Web Developer , Almohtaseb
Date Posted: 2016/10/26
Muhammad Umar Javed
by Muhammad Umar Javed , Senior Software Engineer , Synergy-IT Pakistan

I think options 1,4 and 5 are correct which is option C. The garbage collector collects any unreferenced memory and memory consumed by managed resources. However it does not free memory on stack, close database connections or files.

Nuzhat Khan
by Nuzhat Khan , Software Architect , Beauceron Security

The correct option is - Garbage Collector does NOT free memory on the stack or close any unclosed files or collections

More Questions Like This

Do you need help in adding the right keywords to your CV? Let our CV writing experts help you.