K-means clustering algorithm in python
Avoid comments that are identical to the code:

# check if clusters have converged  &lt;-- Remove this
def has_converged(centroids, old_centroids, iterations):




MAX_ITERATIONS = 1000


Constants should be put at the top of the file to be easier to tweak.



Separate calculations from IO, your function kmeans should return the values and then another function (maybe pretty_format_k_means) should create a human readable message.



# k = number of clusters
# c = initial list of centroids (if provided)


Multi-character variable names are allowed, rename your variables (and function arguments) to more meaningful names, and then you can delete the comments.