​点击打开链接​

A. Vanya and Cards

time limit per test

memory limit per test

input

output

x

n

 - x to x.

Input

n (1 ≤ n ≤ 1000) — the number of found cards and x (1 ≤ x ≤ 1000) — the maximum absolute value of the number on a card. The second line contains n space-separated integers — the numbers on found cards. It is guaranteed that the numbers do not exceed x

Output

Print a single number — the answer to the problem.

Examples

input

3 2 -1 1 2

output

1

input

2 3 -2 -2

output

2

Note

In the first sample, Vanya needs to find a single card with number -2.

In the second sample, Vanya needs to find two cards with number 2. He can't find a single card with the required number as the numbers on the lost cards do not exceed 3 in their absolute value.

题挺简单的,但是读不懂题意,唉~~,还是阅读不够好。

#include<bits/stdc++.h>
using namespace std;
int main()
{
int n,x,w;
cin>>n>>x;
int sum=0;
for(int i=0;i<n;i++)
{
cin>>w;
sum+=w;
}
if(sum<0)
sum=-sum;
if(sum%x==0)
cout<<sum/x<<endl;
else
cout<<sum/x+1<<endl;
return 0;
}