#include <bits/stdc++.h>
using namespace std;
long long dist(long long x, long long y, long long a, long long b) {
  long long ret = (x - a) * (x - a);
  ret += ((y - b) * (y - b));
  ret = ceil(sqrt(ret));
  return ret;
}
int main() {
  int cases, caseno = 0, n, i, j, k, cnt, sum, x, y;
  cin >> n >> x >> y >> i >> j;
  long long d = dist(x, y, i, j);
  cout << (d + n + n - 1) / (n + n) << '\n';
  return 0;
}
