#include <bits/stdc++.h>
using namespace std;
double r, x, y, x_, y_;
double eps = 1e-6;
int main() {
  cin >> r >> x >> y >> x_ >> y_;
  double d = sqrt((y - y_) * (y - y_) + (x - x_) * (x - x_));
  if (fabs(x - x_) < eps && fabs(y - y_) < eps)
    printf("0");
  else {
    if (fabs(d - r) < eps)
      printf("1");
    else {
      d -= r;
      int c = d / (r * 2.0);
      double cc = c;
      d = d - cc * r * 2.0;
      if (fabs(d - r) < eps)
        c++;
      else
        c += 2;
      printf("%d", c);
    }
  }
  return 0;
}
