Pregunta de entrevista de AppNexus

No difficult problems, just some basic programming practice.