#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int n, k;
  cin >> n >> k;
  int a[n];
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  int s = 0;
  int m = 0;
  vector<pair<int, int> > ops;
  while (k > 0) {
    int mx = 0;
    int mn = 0;
    for (int i = 1; i < n; i++) {
      if (a[i] < a[mn]) {
        mn = i;
      }
      if (a[i] > a[mx]) {
        mx = i;
      }
    }
    if (mx == mn) break;
    a[mx]--;
    a[mn]++;
    m++;
    ops.push_back(make_pair(mx + 1, mn + 1));
    k--;
  }
  int mx = 0;
  int mn = 0;
  for (int i = 1; i < n; i++) {
    if (a[i] < a[mn]) {
      mn = i;
    }
    if (a[i] > a[mx]) {
      mx = i;
    }
  }
  cout << a[mx] - a[mn] << " " << m << "\n";
  for (int i = 0; i < ops.size(); i++) {
    cout << ops[i].first << " " << ops[i].second << "\n";
  }
  return 0;
}
