#include <bits/stdc++.h>
int main() {
  int r, x, y, x1, y1, a, b;
  long int p;
  scanf("%d %d %d %d %d", &r, &x, &y, &x1, &y1);
  a = fabs(x - x1);
  b = fabs(y - y1);
  p = (a * a) + (b * b);
  p = ceil(sqrt(p));
  if (p % 2 != 0)
    p = ceil((float)(p / 2.0) / r);
  else
    p = ((p / 2) / r);
  printf("%ld\n", p);
  return 0;
}
