
- This event has passed.
Competitive Programming
October 12, 2022 @ 6:00 pm - 8:00 pm
Homework:
Given two integer arrays arr1 and arr2, and the integer d, return the distance value between the two arrays.
The distance value is defined as the number of elements arr1[i] such that there is not any element arr2[j] where |arr1[i]-arr2[j]| <= d.
Input: arr1 = [4,5,8], arr2 = [10,9,1,8], d = 2
Output: 2