renamed sample without replacement
implemented kmeans example