#include <bits/stdc++.h>
using namespace std;
int dx[] = {0, 1, 0, -1, 1, 1, -1, -1};
int dy[] = {1, 0, -1, 0, 1, -1, 1, -1};
void fast() {
  std::ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  cout.tie(nullptr);
}
long long arr[(int)1e5 + 10];
vector<long long> v;
long long valid(int n, long long k) {
  for (int i = 1; i <= n; i++) {
    v.push_back(arr[i] + i * k);
  }
  sort(v.begin(), v.end());
  long long ret = 0;
  for (int i = 0; i < k; i++) ret += v[i];
  v.clear();
  return ret;
}
pair<long long, long long> solve(int n, long long s) {
  long long l = 1, r = n;
  pair<long long, long long> res = {0, 0};
  while (l <= r) {
    long long mid = (l + r) / 2;
    long long ret = valid(n, mid);
    if (ret <= s) {
      res = {mid, ret};
      l = mid + 1;
    } else
      r = mid - 1;
  }
  return res;
}
int main() {
  fast();
  int n;
  long long s;
  cin >> n >> s;
  for (int i = 1; i <= n; i++) cin >> arr[i];
  pair<long long, long long> res = solve(n, s);
  cout << res.first << " " << res.second << "\n";
}
