#include <bits/stdc++.h>
using namespace std;
const double esp = 1e-6;
int main() {
  long long r, x, y, x1, y1;
  scanf("%I64d%I64d%I64d%I64d%I64d", &r, &x, &y, &x1, &y1);
  if (x == x1 && y == y1) {
    printf("0\n");
    return 0;
  }
  double dis = sqrt((x - x1) * (x - x1) + (y - y1) * (y - y1));
  int k = (int)(dis / (double)(2 * r) + esp);
  if (dis / (double)(2 * r) - k > esp) k++;
  printf("%d\n", k);
  return 0;
}
