#include <bits/stdc++.h>
using namespace std;
void solve() {
  long long r, x, y, x1, y1;
  cin >> r >> x >> y >> x1 >> y1;
  long long dist = ceil(sqrt((x - x1) * (x - x1) + (y - y1) * (y - y1)));
  if (dist == 0) {
    cout << 0 << "\n";
  } else if (dist % (r * 2) == 0) {
    cout << dist / (r * 2);
  } else {
    cout << dist / (r * 2) + 1 << "\n";
  }
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int t = 1;
  while (t--) {
    solve();
  }
}
