HSBC Interview Question

How to fix an OutOfMemoryError