A park ranger logged where visitors set up picnics, as [x, y] points in metres from the gate. She doesn't know how many popular spots there are. Inertia always falls as k grows, so she uses the silhouette score instead.
Task: write best_k(points, ks).
k in ks, in the given order, fit KMeans(n_clusters=k, random_state=0, n_init=10) on the points as given. Don't scale them.silhouette_score(points, labels)."scores": the silhouette scores in the same order as ks, each rounded to 3 decimal places"best_k": the k with the highest scoreEvery k in ks is at least 2. No two scores tie.