The steps of the k-means algorithm