#include <bits/stdc++.h>
using namespace std;
int main() {
  int r, x, y, x1, y1;
  scanf("%d %d %d %d %d", &r, &x, &y, &x1, &y1);
  int difx = abs(x - x1);
  int dify = abs(y - y1);
  float dist = ceil(sqrt(difx * difx + dify * dify));
  long long ans = ceil(dist / (2 * r));
  printf("%I64d", ans);
  return 0;
}
