Post Office Problem(LintCode 435):

Problem