Solutions by Sorting

Several of these statistics can be computed easily (constant time) if L is already sorted.

L[0], L[n-1], (L[0]+L[n-1])/2, $L[\lceil n/2 \rceil]$.

We'll talk more about all of these in a moment, and you'll look at mode and rank in the homework.


next up previous
Next: Solutions if Unsorted Up: COMPUTING STATISTICS Previous: Facts About Statistics