Given an array of integers, and an integer N, find the length of the longest “N-stable” continuous subarray.
An array is defined to be “N-stable” when the pair-wise difference between any two elements in the array is smaller or equal to N.
A subarray of a 0-indexed integer array is a contiguous non-empty sequence of elements within an array.
For instance, for array [ 4, 2, 3, 6, 2, 2, 3, 2, 7 , 4], and N = 2
The return value should be 4, since the longest 1-stable subarray is [ 2, 2, 3, 2 ]