#include <bits/stdc++.h>
using namespace std;
int main() {
  int r, x, y, xf, yf;
  cin >> r >> x >> y >> xf >> yf;
  float dist = sqrt((x - xf) * (x - xf) + (y - yf) * (y - yf));
  if (dist - r > 0)
    cout << (int)dist / r - 1;
  else
    cout << 0;
  return 0;
}
