print("Enter the coordinates")
X1=int(input(" X1 = "))
Y1=int(input(" Y1 = "))
X2=int(input(" X2 = "))
Y2=int(input(" Y2 = "))
X3=int(input(" X3 = "))
Y3=int(input(" Y3 = "))
M1=(X1+X2+X3)/3
M2=(Y1+Y2+Y3)/3
print("\n","The coordinates of A = (",X1,",",Y1,")","\n","The coordinates of B = (",X2,",",Y2,")","\n","The coordinates of C = (",X3,",",Y3,")","\n")
print("As, centroid = ","X1+X2+X3",",","Y1+Y2+Y3")
print(" -------- --------")
print(" 3 3 ")
print("Therefore, centroid of triangle ABC = (",M1,",",M2,")")