jason.lu 6 years ago
parent
commit
561672014f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      js/newCommon.js

+ 1 - 1
js/newCommon.js

@@ -98,7 +98,7 @@ const DataObjectList = function (name) {
 
     while (i !== j) {
       while ((comp(inputVar[j], pivot) > 0) && i < j) { j--; }
-      while ((comp(inputVar[j], pivot) <= 0) && i < j) { i++; }
+      while ((comp(inputVar[i], pivot) <= 0) && i < j) { i++; }
       if (i < j) { // 如果i==j跳出外层while
         const t = inputVar[i];
         inputVar[i] = inputVar[j];