#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int r, x1, y1, x2, y2, d = 0, x = 0, y = 0;
  cin >> r >> x1 >> y1 >> x2 >> y2;
  x = abs(x1 - x2);
  y = abs(y1 - y2);
  double z;
  z = sqrt((x * x) + (y * y)) / (2 * r);
  d = sqrt((x * x) + (y * y)) / (2 * r);
  if (z > d) {
    cout << d + 1;
    return 0;
  } else
    cout << d;
  return 0;
}
