Topic: Two Pointer Problem / Level: intermediate

Problem: Given a sorted array, find the smallest subarray where the difference between the maximum and minimum element is less than or equal to a target using two pointers.

Run the code to see the output here...