cielseven's picture
add benchmark corpora, groundtruth, symexec scripts and coverage docs
bff4ec7
|
Raw History Blame Contribute Delete
451 Bytes

Stable Counting Sort

Description

Sort integers from the fixed range $[0,99]$ in nondecreasing order using stable counting sort.

Input

The function receives an integer array a and its length $n$.

Output

The same array contains the input values in nondecreasing order.

Constraints

  • $0 \le n \le 100$.
  • $0 \le a_i < 100$ for every element.

Source

Classical counting-sort problem reconstructed from the verified C artifact.