#include <bits/stdc++.h>
using namespace std;
const long long M = 1e9 + 7;
const double PI = acos(-1);
const double EPS = 1e-12;
const long long arrSize = 2000005;
long long arr[arrSize];
int main() {
  int tc = 1, kasus = 1;
  while (tc--) {
    long long r, x[2], y[2];
    scanf("%lld %lld %lld %lld %lld", &r, &x[0], &y[0], &x[1], &y[1]);
    double dx = (x[0] - x[1]);
    double dy = (y[0] - y[1]);
    long long ans = (ceil((double)sqrt(dx * dx + dy * dy))) / (2.0 * r);
    printf("%lld\n", ans);
  }
}
