#include <bits/stdc++.h>
using namespace std;
typedef struct node {
  int val, ind;
} node;
bool operator<(node a, node b) { return a.val < b.val; }
int main() {
  int r, x, y, x2, y2;
  cin >> r >> x >> y >> x2 >> y2;
  double min_dist = ((x2 - x) * (x2 - x)) + ((y2 - y) * (y2 - y));
  min_dist = pow(min_dist, 0.5);
  int ans;
  int in_min = (int)min_dist;
  if (min_dist == in_min) {
    if ((int)min_dist % (2 * r) == 0) {
      ans = in_min / (2 * r);
      cout << ans << endl;
      return 0;
    } else {
      ans = in_min / (2 * r);
      ans++;
    }
  }
  ans = in_min / (2 * r);
  ans++;
  cout << ans << endl;
  return 0;
}
