Ds with python help me | Sololearn: Learn to code for FREE!

+1

Ds with python help me

Help me with last project please

12/21/2020 9:11:14 AM

Bat-Ochir Artur

4 Answers

New Answer

+2

Dinners on me

+2

Lothar Yes! lol Anyways, in the last project DS with python I’m getting incorrect result on 3,4 and 5th test case but correct on 1, and 2. here’s my code: n = int(input()) X = [] for i in range(n): X.append([float(x) for x in input().split()]) from sklearn.cluster import KMeans import numpy as np from sklearn.metrics.pairwise import euclidean_distances import math X=np.array(X) kmeans = KMeans(n_clusters=2,random_state=1) kmeans.fit(X) s=(kmeans.cluster_centers_) for a in s: print(np.around(a,2))

+1

i pay for your dinner whoever helps me

+1

Bat-Ochir Artur , do you also pay for my flight and my hotel? That is great - thanks!!! Ok - back to your problem. The description you gave us is rather imprecise. if you really expect some help, you should give us a clear task description and also the code you have done for this task, and explain us the problem you are faced with!