#include <bits/stdc++.h>
using namespace std;
int main() {
  int r, x, y, x1, y1;
  cin >> r >> x >> y >> x1 >> y1;
  int s1 = (x - x1) * (x - x1) + (y - y1) * (y - y1);
  int m = sqrt(s1) / (r);
  if (m <= 1)
    cout << m << endl;
  else
    cout << m - 1 << endl;
  return 0;
}
