#include <bits/stdc++.h>
using namespace std;
int main() {
  int x1, y1, x2, y2, r;
  while (scanf("%d%d%d%d%d", &r, &x1, &y1, &x2, &y2) == 5) {
    long long dis;
    int ans = 0;
    dis = (x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2);
    if (dis < 4 * r * r) {
      ans = 1;
      if (dis == 0) ans = 0;
    } else {
      for (int i = 1;; i++) {
        int t = 2 * r * i;
        if (t * t >= dis) {
          ans = i;
          break;
        }
      }
    }
    printf("%d\n", ans);
  }
}
