Garbage collection MCQs

By: Prof. Dr. Fazal Rehman | Last updated: May 14, 2025

35
Score: 0
Attempted: 0/35
Subscribe
1. : What is garbage collection?



2. : Which of the following languages primarily uses garbage collection?



3. : What is the main purpose of garbage collection?



4. : Which of the following is NOT a type of garbage collection?



5. : In the mark-and-sweep algorithm, what is the first step?



6. : What does reference counting do?



7. : What happens when an object’s reference count reaches zero?



8. : Which garbage collection method involves dividing memory into generations?



9. : In garbage collection, what does the term “root set” refer to?



10. : Which of the following can cause memory leaks?



11. : What is a common drawback of garbage collection?



12. : What does “stop-the-world” mean in the context of garbage collection?



13. : What is the role of a garbage collector in a programming language?



14. : Which of the following is a characteristic of the mark-and-sweep algorithm?



15. : How does a tracing garbage collector work?



16. : What is a potential advantage of using garbage collection?



17. : Which algorithm is primarily used in languages like C# for garbage collection?



18. : What is the main limitation of reference counting?



19. : Which of the following is a sign of a memory leak?



20. : What is the purpose of garbage collection in Java?



21. : What does the term “finalization” mean in garbage collection?



22. : Which of the following can improve the efficiency of garbage collection?



23. : What is “heap fragmentation”?



24. : In what scenario is garbage collection typically invoked?



25. : What is the main challenge with automatic garbage collection?



26. : How can developers help minimize garbage collection overhead?



27. : Which method is NOT a part of garbage collection in Java?



28. : What happens if garbage collection is disabled in a language that relies on it?



29. : What is the role of a “garbage collector” in a virtual machine?



30. : Which technique does not rely on a garbage collector?



31. : Which garbage collection algorithm can lead to pauses in application execution?



32. : What is “concurrent garbage collection”?



33. : What is a significant benefit of generational garbage collection?



34. : In which scenario is manual garbage collection preferable?



35. : What does “tracing” in garbage collection refer to?



 

 

Data Structures MCQs

Basic Concepts

  1. Introduction to Data Structures
  2. Complexity Analysis MCQs

Linear Data Structures MCQs

  1. Arrays MCQs
  2. Linked Lists MCQs
  3. Stacks MCQs
  4. Queues MCQs

Non-Linear Data Structures MCQs

  1. Trees MCQs
  2. Heaps MCQs
  3. Graphs MCQs

Hashing MCQs MCQs

  1. Hash Tables

Sorting and Searching Algorithms MCQs 

  1. Sorting Algorithms MCQs
  2. Searching Algorithms MCQs

Miscellaneous

  1. Memory Management in data structures MCQs
  2. String Manipulation Algorithms MCQs
  1. Data Structures MCQs 1
  2. Data Structures MCQs 2
  3. Data Structures MCQs 3
  4. Data Structures MCQs 4
  5. Data Structures MCQs 5
  6. Stacks Solved MCQs
  7. Queues MCQs
  8. pointer mcqs
  9. Array MCQs

 

All Copyrights Reserved 2025 Reserved by T4Tutorials