restore the first part of the kmeans main function and change the text to reflect different code formattin