code: function squaredEuclideanDistance (point1, point2) {
      var result = 0,
          i = 0;
  
      for (; i < point1.length; i++) {
          result += Math.pow(point1[i] - point2[i], 2);
      }
  
      return result;
  }
docs: Get the squared euclidean distance from two points of arbitrary, but equal, dimensions
  @param {Array} point1
  @param {Array} point2
  @returns {number} Squared euclidean distance