Sollicitatievraag bij Schneider Electric

Find the minimum distance between given two elements in an array.