#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, x, y, ax, ay;
  scanf("%d%d%d%d%d", &n, &x, &y, &ax, &ay);
  double asx = abs(ax - x), asy = abs(ay - y);
  double s = sqrt(asx * asx + asy * asy);
  n += n;
  s = ceil(s);
  printf("%d\n", ((int)s + n - 1) / n);
  return 0;
}
