Problem 2317. Distance of the centroids of the balls

Created by Marco Castelli in Community

Given n balls of radius r and the vector p (nx3) with all position (x,y,z) of the balls, return the symmetric matrix A (nxn) containing all distance between the centroid of all balls (diagonal terms should be all 0).

Two or more balls can overlap.

Solution Stats

66.67% Correct | 33.33% Incorrect
Last solution submitted on Mar 29, 2019

Solution Comments