#include <bits/stdc++.h>
using namespace std;
struct st1 {
  int so, vt;
};
st1 a[101];
struct st2 {
  int cho, nhan;
};
st2 doi[1001];
int lech[1001];
int n, k;
bool sx(st1 a, st1 b) { return a.so < b.so; }
void solve() {
  int i, min1, in;
  sort(a + 1, a + n + 1, sx);
  lech[0] = a[n].so - a[1].so;
  for (i = 1; i <= k; i++) {
    a[1].so++;
    a[n].so--;
    doi[i].cho = a[n].vt;
    doi[i].nhan = a[1].vt;
    sort(a + 1, a + n + 1, sx);
    lech[i] = a[n].so - a[1].so;
  }
  min1 = lech[0];
  in = 0;
  for (i = 1; i <= k; i++) {
    if (min1 > lech[i]) {
      min1 = lech[i];
      in = i;
    }
  }
  cout << min1 << " " << in << endl;
  for (i = 1; i <= in; i++) {
    cout << doi[i].cho << " " << doi[i].nhan << endl;
  }
}
void input() {
  int i;
  for (i = 1; i <= n; i++) {
    cin >> a[i].so;
    a[i].vt = i;
  }
  solve();
}
int main() {
  while (cin >> n >> k) {
    input();
  }
  return 0;
}
