Pair with the given difference
Given an unsorted array and an integer x, the task is to find if there exists a pair of elements in the array whose absolute difference is x. Examples: Input: arr[] = [5, 20, 3, 2, 50, 80], x = 78Output: YesExplanation: The pair is {2, 80}. Input: arr[] = [90, 70, 20, 80, 50], x = 45Output: NoExplan