🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: JVM Memory and Garbage Collection: all 10 questions

Quiz: JVM Memory and Garbage Collection · Question 8 of 10

Why does generational GC collect the young generation more often?

Why does generational GC collect the young generation more often?

  1. A.Young objects are larger
  2. B.Old objects cannot be collected
  3. C.The young generation is stored on the stack
  4. D.Most objects die young, so collecting Eden frees a lot of memory quickly and cheaply
Answer & explanation

Correct answer: Most objects die young, so collecting Eden frees a lot of memory quickly and cheaply

Only the few survivors are copied; everything else in Eden is reclaimed at once.

Can you get the rest right without peeking?

Take the timed Quiz: JVM Memory and Garbage Collection quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →