Pergunta de entrevista da empresa Bloomberg

How does the java garbage collector work?