Pergunta de entrevista da empresa Amazon

Design an executor for tasks with dependencies.