We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fc0cf49 commit 82bfa6bCopy full SHA for 82bfa6b
dsa-solutions/lc-solutions/0400-0499/0493-reverse-pairs.md
@@ -1,10 +1,17 @@
1
---
2
id: reverse-pairs
3
title: Reverse Pairs
4
-sidebar_label: 0493 - Reverse Pairs
+sidebar_label: 493-Reverse-Pairs
5
tags:
6
- - Leetcode
+ - Array
7
+ - Binary Search
8
+ - Divide and conquer
9
+ - Binary Indexed Tree
10
+ - Segment Tree
11
- Merge Sort
12
+ - Ordered Set
13
+description: The problem is to reverse the pairs.
14
+sidebar_position: 2667
15
16
17
## Problem Statement
@@ -204,6 +211,7 @@ class Solution:
204
211
public int reversePairs(int[] nums) {
205
212
return mergeSort(nums, 0, nums.length - 1);
206
213
}
214
+
207
215
public int mergeSort(int[] nums, int left, int right) {
208
216
if (left >= right) {
209
217
return 0;
0 commit comments