Minimum Absolute Difference in an Array

  • + 0 comments

    Python3 1 liner

    return min(map(lambda p: p[1] - p[0], itertools.pairwise(sorted(arr))))