Pergunta de entrevista da empresa Plex Systems, Inc.

Pretty straight forward coding question.