#include <bits/stdc++.h>
using namespace std;
template <class T>
string tostring(T x) {
  ostringstream out;
  out << x;
  return out.str();
}
long long toint(string s) {
  istringstream in(s);
  long long x;
  in >> x;
  return x;
}
int main() {
  int n, x, tmp;
  cin >> n >> x;
  int ans = 0, zero = 0;
  for (int i = 0; i < n; i++) {
    cin >> tmp;
    ans += tmp;
  }
  if (ans == 0) {
    cout << 0 << endl;
  } else {
    ans = ((ans < 0) ? -(ans) : (ans));
    if (ans % x == 0) {
      cout << ans / x << endl;
    } else {
      cout << ans / x + 1 << endl;
    }
  }
  return 0;
}
