#include <bits/stdc++.h>
using namespace std;
int x;
double dis(int x1, int y1, int x2, int y2) {
  return sqrt(powl(labs(x1 - x2), 2) + (powl(labs(y1 - y2), 2)));
}
int main() {
  int r, x1, x2, y1, y2;
  int res = 0;
  cin >> r >> x1 >> y1 >> x2 >> y2;
  if (x1 == x2 && y1 == y2)
    cout << 0 << endl;
  else {
    double d = dis(x1, y1, x2, y2);
    if (d - (long long)d > 0.00001) res++;
    res += int(d / (2 * r));
    cout << res << endl;
  }
}
