Closest pair of points problem for a one-dimensional (single)  array.