SHARE
TWEET

Untitled

a guest Mar 24th, 2019 75 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. template <int Dim>
  2. double KDTree<Dim>::dist(const Point<Dim>& a, const Point<Dim>& b) const
  3. {
  4.     /**
  5.      * @todo Implement this function!
  6.      */
  7.      double pa = 0;
  8.      for(int i = 0; i < Dim; i++){
  9.        pa+=((a[i] - b[i])*(a[i] - b[i]));
  10.      }
  11.      return pa;
  12. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top