The worst-case input for this
algorithm is a list with no equal
elements.
For such a list, its ith element is
compared with i − 1 elements of
the auxiliary list of distinct values
seen so far before being added
to the list with a frequency of 1.
As a result, the worst-case number
of comparisons made by this
algorithm in creating the
frequency list is