It is dark times in Berland. Berlyand opposition, funded from a neighboring state, has organized a demonstration in Berland capital Bertown. Through the work of intelligence we know that the demonstrations are planned to last for k days.

Fortunately, Berland has a special police unit, which can save the country. It has exactly n soldiers numbered from 1 to n. Berland general, the commander of the detachment, must schedule the detachment's work in these difficult k days. In each of these days, the general must send a certain number of police officers to disperse riots. Since the detachment is large and the general is not very smart, he can only select a set of all soldiers numbered from l to r, inclusive, where l and r are selected arbitrarily.

Now the general has exactly two problems. First, he cannot send the same group twice — then soldiers get bored and they rebel. Second, not all soldiers are equally reliable. Every soldier has a reliability of ai. The reliability of the detachment is counted as the sum of reliabilities of soldiers in it. The reliability of a single soldier can be negative, then when you include him in the detachment, he will only spoil things. The general is distinguished by his great greed and shortsightedness, so each day he sends to the dissolution the most reliable group of soldiers possible (that is, of all the groups that have not been sent yet).

The Berland Government has decided to know what would be the minimum reliability of the detachment, sent to disperse the demonstrations during these k days. The general himself can not cope with such a difficult task. Help him to not embarrass himself in front of his superiors!

Input

The first line contains two integers n and k <image> — the number of soldiers in the detachment and the number of times somebody goes on duty.

The second line contains n space-separated integers ai, their absolute value doesn't exceed 109 — the soldiers' reliabilities.

Please do not use the %lld specifier to read or write 64-bit integers in С++, it is preferred to use cin, cout streams of the %I64d specifier.

Output

Print a single number — the sought minimum reliability of the groups that go on duty during these k days.

Examples

Input

3 4
1 4 2


Output

4


Input

4 6
2 -1 2 -1


Output

1


Input

8 10
1 -2 3 -4 5 -6 7 -8


Output

2
#include <bits/stdc++.h>
using namespace std;
const int nit = 1 << 18;
int it[2 * nit];
int it_get(int l, int r) {
  l += nit, r += nit;
  int res = 0;
  while (l < r) {
    if (l % 2 == 1) res += it[l++];
    if (r % 2 == 0) res += it[r--];
    l /= 2;
    r /= 2;
  }
  if (l == r) res += it[l];
  return res;
}
long long test(int n, long long *a, long long x) {
  long long sum[n + 1];
  sum[0] = 0;
  for (int i = 0; i < n; i++) sum[i + 1] = sum[i] + a[i];
  vector<pair<long long, int> > ss;
  for (int i = 0; i <= n; i++) ss.push_back(make_pair(sum[i], i));
  sort(ss.begin(), ss.end());
  int rp[n + 1];
  for (int i = 0; i <= n; i++) rp[ss[i].second] = i;
  for (int i = 0; i <= n; i++) it[nit + i] = 1;
  for (int i = nit - 1; i > 0; i--) it[i] = it[i * 2] + it[i * 2 + 1];
  long long res = 0;
  for (int i = 0; i < n; i++) {
    for (int k = rp[i] + nit; k >= 1; k /= 2) it[k]--;
    int mi = 0, ma = n + 1;
    while (mi < ma) {
      int av = (mi + ma) / 2;
      if (ss[av].first >= x + sum[i])
        ma = av;
      else
        mi = av + 1;
    }
    int bonus = it_get(mi, n);
    res += bonus;
  }
  return res;
}
int main() {
  int n;
  long long k;
  cin >> n >> k;
  long long a[n];
  for (int i = 0; i < n; i++) cin >> a[i];
  long long mn = (long long)-1e15, mx = (long long)1e15;
  while (mn < mx) {
    long long av = (mn + mx + 1) / 2;
    long long cnt = test(n, a, av);
    if (cnt < k)
      mx = av - 1;
    else
      mn = av;
  }
  cout << mn << endl;
  return 0;
}
