Count Inversions Of An Array Leetcode