#include <bits/stdc++.h>
using namespace std;
struct ee {
  int d;
  int y;
};
ee e[120];
ee r[1200];
bool ok(ee a, ee b) { return a.y > b.y; }
int main() {
  int n;
  int k;
  while (cin >> n >> k) {
    memset(e, 0, sizeof(e));
    memset(r, 0, sizeof(r));
    for (int i = 0; i < n; i++) {
      cin >> e[i].y;
      e[i].d = i + 1;
    }
    sort(e, e + n, ok);
    int m = 0, m2 = 0;
    int ss;
    for (int i = 0; i < k; i++) {
      ss = e[0].y - e[n - 1].y;
      if (ss <= 1) {
        break;
      }
      e[0].y--;
      e[n - 1].y++;
      r[i].d = e[0].d;
      r[i].y = e[n - 1].d;
      sort(e, e + n, ok);
      m++;
      if (ss > e[0].y - e[n - 1].y) {
        m2 = m;
        ss = e[0].y - e[n - 1].y;
      }
    }
    cout << ss << " " << m2 << endl;
    for (int i = 0; i < m2; i++) {
      cout << r[i].d << " " << r[i].y << endl;
    }
  }
  return 0;
}
