'Why do we use the term "non-descending" instead of "ascending" in sorting algorithms?
In the sorting algorithms like heapsort or quicksort, why do standard publications or research papers prefer the term "non-descending" or "non-ascending" when they can simply use ascending or descending respectively? I mean anyways the meaning is going to be the same.
Solution 1:[1]
"Ascending" is where for all elements 0 through length-2 as i in the array, element i+1 > element i. "Non-descending" means element i+1 >= element i rather than just greater than.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Chris Cousins |
