#include <bits/stdc++.h>
using namespace std;
int main() {
  long long r, x0, y0, x1, y1;
  cin >> r >> x0 >> y0 >> x1 >> y1;
  long long d2 = (x0 - x1) * (x0 - x1) + (y0 - y1) * (y0 - y1);
  if (d2 == 0)
    cout << 0;
  else if (4 * r * r >= (x0 - x1) * (x0 - x1) + (y0 - y1) * (y0 - y1))
    cout << 1;
  else {
    double dd = sqrt(d2) / (2 * r);
    long long di = dd;
    if (dd > di) di++;
    cout << di;
  }
}
