Leetcode Daily Question
2.46K subscribers
517 files
2.16K links
Why are you asking me to do Leetcode for this CSS job?
Download Telegram
Leetcode 2021-04-17
🟡 220.contains-duplicate-iii
#sort #ordered-map

Given an integer array nums and two integers k and t, return true if there are two distinct indices i and j in the array such that abs(nums[i] - nums[j]) <= t and abs(i - j) <= k.
Input: nums = [1,2,3,1], k = 3, t = 0
Output: true