Given an array of elements, find the smallest
difference between two consecutive elements.
The distance between elements cannot be negative,
so you will need to use the abs
function.
The comparisons do not wrap around, so do not compare the difference between the first and last elements. If the array has 1 or fewer elements, the minimum distance is 0.