W3
Teacher
Explore
Browse by field
Artificial Intelligence
Accounting & Finance
Information Technology
Show all fields
Interview Q&A
All Interview Questions
Beginner
Intermediate
Advanced
Practice
MCQs
Quizzes
Mock Interviews
About
Light
Dark
Auto
Sign in
Get Started
Search interview questions
Search
140 questions for “Garbage Collection”
Found in 1 field. Select a question to see its full answer.
Matching topics
C#
Memory &
Garbage
Collection
18
Java
Garbage
Collection
15
Python
Memory Management &
Garbage
Collection
15
JavaScript
Memory Management &
Garbage
Collection
10
Java
Collection
s Framework
1
Information Technology
140 questions in 8 technologies
#
Question
Technology
Topic
Level
1
What does it mean for an object to be 'eligible for
garbage
collection
' in terms of reachability from GC roots?
Java › Garbage Collection
Java
Garbage
Collection
Beginner
2
What is
garbage
collection
in the JVM, and what fundamental problem does it solve compared to manual memory management (like in C/C++)?
Java › Garbage Collection
Java
Garbage
Collection
Beginner
3
What are the four types of references in java.lang.ref (strong, soft, weak, phantom), and how does each affect an object's eligibility for
garbage
collection
?
Java › Garbage Collection
Java
Garbage
Collection
Intermediate
4
What is the difference between a stop-the-world (STW) GC pause and a concurrent GC phase, and why can't
garbage
collection
be made entirely concurrent with zero pauses?
Java › Garbage Collection
Java
Garbage
Collection
Intermediate
5
How would you diagnose a memory leak in a Java application (where memory usage grows unboundedly despite
garbage
collection
running) using heap dump analysis, and what common patterns cause 'leaks' in a
garbage
-collected language?
Java › Garbage Collection
Java
Garbage
Collection
Advanced
6
How would you determine whether an application is spending an excessive amount of time in
garbage
collection
(GC overhead) relative to actual application work, and what JVM flags or tools help measure and diagnose this?
Java › Garbage Collection
Java
Garbage
Collection
Advanced
7
How does
garbage
collection
in .NET work, and what three phases does a
collection
cycle go through?
C# › Memory & Garbage Collection
C#
Memory &
Garbage
Collection
Beginner
8
How does
garbage
collection
work in .NET?
C# › Memory & Garbage Collection
C#
Memory &
Garbage
Collection
Beginner
9
What is a memory leak in JavaScript, given that it has automatic
garbage
collection
?
JavaScript › Memory Management & Garbage Collection
JavaScript
Memory Management &
Garbage
Collection
Beginner
10
What are .NET's
garbage
collection
'generations,' and what's the core assumption behind this design?
C# › Memory & Garbage Collection
C#
Memory &
Garbage
Collection
Beginner
Show all 140 questions in Information Technology