Hamro Patro interview question

explain memory management in java?