#include <bits/stdc++.h>
using namespace std;
int a[2222];
map<int, int> M;
bool IsOk(int m, int x, int c) {
  map<int, int>::iterator it;
  for (it = M.begin(); it != M.end(); it++) {
    if (it->first > m)
      c += it->second;
    else if (it->second > x)
      c += (it->second - x);
    else
      ;
  }
  for (int i = 1; i <= m; i++) {
    if (M[i] >= x)
      continue;
    else
      c -= (x - M[i]);
  }
  return (c >= 0);
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int i, j, n, m, l, r, mid, c = 0, d = 0;
  cin >> n >> m;
  for (i = 0; i < n; i++) {
    cin >> a[i];
    M[a[i]]++;
  }
  l = 1, r = n;
  while (l < r) {
    mid = (l + r + 1) / 2;
    if (IsOk(m, mid, c))
      l = mid;
    else
      r = mid - 1;
  }
  assert(IsOk(m, l, c));
  for (i = 1; i <= m; i++) {
    if (M[i] >= l)
      continue;
    else
      d += (l - M[i]);
  }
  cout << l << ' ' << d << '\n';
  for (i = 1; i <= m; i++) {
    j = 0;
    while (M[i] < l && j < n) {
      if (a[j] != i) {
        if (a[j] > m || M[a[j]] > l) {
          M[a[j]]--;
          a[j] = i;
          M[i]++;
        }
      }
      j++;
    }
  }
  for (i = 0; i < n; i++) cout << a[i] << ' ';
  cout << '\n';
  return 0;
}
