Given an array of integers nums, return the total count of good pairs.
A pair (i, j) is considered good if nums[i] == nums[j] and i j.
Constraints:
nums.length
nums[i]
Given an array of integers nums, return the total count of good pairs.
A pair (i, j) is considered good if nums[i] == nums[j] and i j.
Constraints:
nums.length
nums[i]