#include <bits/stdc++.h>
#pragma comment(linker, "/STACK:10000000")
using namespace std;
using ll = long long;
class timer {
 public:
  timer() { drop(); };
  double drop() {
    double time = double(clock() - last_drop) / CLOCKS_PER_SEC;
    last_drop = clock();
    return time;
  };
  void drop(string report) {}

 private:
  int last_drop;
};
int readint() {
  int x;
  scanf("%d", &x);
  return x;
}
void solve() {
  int n = readint();
  int m = readint();
  vector<int> a(n);
  vector<vector<int>> ind(m, vector<int>());
  vector<int> vacant;
  for (int i = 0; i < n; i++) {
    a[i] = readint() - 1;
    if (a[i] >= m)
      vacant.push_back(i);
    else
      ind[a[i]].push_back(i);
  }
  int k = n / m;
  for (int i = 0; i < m; i++) {
    while (ind[i].size() > k + 1) {
      vacant.push_back(ind[i].back());
      ind[i].pop_back();
    }
  }
  for (int i = 0; i < m; i++) {
    while (ind[i].size() > k) {
      vacant.push_back(ind[i].back());
      ind[i].pop_back();
    }
  }
  reverse(vacant.begin(), vacant.end());
  int count = 0;
  for (int i = 0; i < m; i++) {
    while (ind[i].size() < k) {
      a[vacant.back()] = i;
      ind[i].push_back(vacant.back());
      vacant.pop_back();
      count++;
    }
  }
  printf("%d %d\n", k, count);
  for (int i = 0; i < n; i++)
    printf("%d%c", a[i] + 1, (i + 1 == n) ? '\n' : ' ');
}
int main() {
  solve();
  return 0;
}
