Pregunta de entrevista de Uber

It's just basic algorithms stuff, can you sort through this, memory management techniques, etc. Nothing particularly difficult.