#include #include using namespace std; const int n=4; // no. of particles double x[n] = {0., 1., 3., 5}; // coordinates of particles double y[n] = {0., 5., 3., 2}; double z[n] = {6., 2., 3., 6}; int main(){ double xsum=0, ysum=0, zsum=0; // sum of coordinates for (int i=0; i