Don't know why this code is running

Revision en3, by silenttkillerr, 2023-09-17 04:03:08

I was solving a problem from Leetcode https://leetcode.com/problems/count-pairs-of-points-with-distance-k/

In this problem i am only checking from (i to i+100) and it passed , i not have any proof how pair will exist only till i+100,can anyone provide any proof or intuition.

code : https://leetcode.com/submissions/detail/1051363856/

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en3 English silenttkillerr 2023-09-17 04:03:08 1101
en2 English silenttkillerr 2023-09-17 04:02:15 6 Tiny change: 'ition.\n\nclass So' -> 'ition.\n\n```\nclass So'
en1 English silenttkillerr 2023-09-17 04:01:54 1429 Initial revision (published)