Suppose we run the K-means clustering algorithm on a one-dimensional dataset, i.e. $p = 1$, so that each observation consists of a single real number.
We assume that these real numbers are distinct.
We need to show that the algorithm terminates in at most $n^{K-1}$ steps.
I know that I can find an upper bound for the number of steps based off of Stirling numbers, but that will be much higher than the required bound.
Any ideas on how to get the $n^{K-1}$ ?