In the editorial solution it’s given as

```
Math.min(min1, array[i] + i);
Math.max(max2, array[i] - i);
```

We’re only finding { A[i] + i } and { A[i] - i }.

But, as per equation, we should also find { A[i] + i } - { A[j] + j } and { A[i] - i } - { A[j] - j } .

Why are we not doing it?