Lumen interview question

How to handle a file? How to allocate memory?