Pergunta de entrevista da empresa Amazon

given an array a, return the indices i,j that minimize |a_i -a_j|