[Solved] Count Number of Bad Pairs LeetCode Contest
![[Solved] Count Number of Bad Pairs LeetCode Contest [Solved] Count Number of Bad Pairs LeetCode Contest](https://realcoder.techss24.com/wp-content/uploads/2022/08/Solved-Count-Number-of-Bad-Pairs-LeetCode-Contest.png)
You are given a 0-indexed integer array nums. A pair of indices (i, j) is a bad pair if i < j and j – i != nums[j] – nums[i]. Return the total number of bad pairs in nums. Count Number of Bad Pairs LeetCode Contest Example 1: Input: nums = [4,1,3,3] Output: 5…