#include <bits/stdc++.h>
using namespace std;
template <typename T, typename U>
void amin(T& a, U b) {
  if (a > b) a = b;
}
template <typename T, typename U>
void amax(T& a, U b) {
  if (a < b) a = b;
}
const long long INF = 1e18;
const int32_t M = 1e9 + 7;
void solve() {
  long long r, x, y, x1, y1;
  cin >> r >> x >> y >> x1 >> y1;
  if (x == x1 && y == y1) {
    cout << 0 << "\n";
    return;
  }
  long long v = (x1 - x) * (x1 - x) + (y1 - y) * (y1 - y);
  long long rad = 4 * r * r;
  if (sqrt(v) <= 2 * r) {
    cout << 1 << "\n";
    return;
  }
  long long ans = 0;
  ans = sqrt(v) / (2 * r);
  double f = sqrt(v) - (2 * r) * ans;
  if (f > 0) ans++;
  cout << ans << "\n";
}
void input() {}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  input();
  int i = 1;
  { solve(); }
}
