Pergunta de entrevista da empresa Clover IT Services

given an array and make it all the element unique at the given sum