#include <bits/stdc++.h>
using namespace std;
double dist(long long x1, long long y1, long long x2, long long y2) {
  return sqrt((x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1));
}
int main() {
  int r, x1, y1, x2, y2;
  cin >> r >> x1 >> y1 >> x2 >> y2;
  x1 == x2&& y1 == y2 ? cout << 0 << "\n"
                      : cout << int(dist(x1, y1, x2, y2) / r) - 1 << "\n";
  return 0;
}
