#include <bits/stdc++.h>
using namespace std;
double Distance(double dX0, double dY0, double dX1, double dY1) {
  return sqrt((dX1 - dX0) * (dX1 - dX0) + (dY1 - dY0) * (dY1 - dY0));
}
int main() {
  double r, x, y, z, w;
  cin >> r >> x >> y >> z >> w;
  r *= 2;
  if (x == z && y == w) {
    cout << "0\n";
    return 0;
  }
  double dist = Distance(x, y, z, w);
  dist /= r;
  cout << ceil(dist) << endl;
}
