small fix in merge sort

This commit is contained in:
Loredana 2018-12-14 00:01:53 +02:00
parent 83acd92ba5
commit 3235804ebf
1 changed files with 1 additions and 1 deletions

View File

@ -34,7 +34,7 @@ public class MergeSort {
while (i < left && j < right) {
if (l[i] < r[j])
if (l[i] <= r[j])
a[k++] = l[i++];
else
a[k++] = r[j++];