#include <bits/stdc++.h>
using namespace std;
int n, m;
int v[2007], cnt[2007];
int main() {
  ios::sync_with_stdio(false);
  cin >> n >> m;
  priority_queue<pair<int, int> > pq;
  for (int i = 0; i < n; ++i) {
    cin >> v[i];
    if (v[i] <= m) {
      cnt[v[i]]++;
    }
  }
  for (int i = 1; i <= m; ++i) {
    if (cnt[i] < n / m) pq.push(make_pair(-cnt[i], i));
  }
  int b, tot = 0;
  for (int i = 0; i < n and pq.size(); ++i) {
    if (v[i] > m or cnt[v[i]] > n / m) {
      if (v[i] <= m) cnt[v[i]]--;
      b = pq.top().second;
      pq.pop();
      v[i] = b;
      cnt[b]++;
      if (cnt[b] < n / m) pq.push(make_pair(-cnt[b], b));
      tot++;
    }
  }
  cout << n / m << " " << tot << endl;
  for (int i = 0; i < n; ++i) {
    cout << v[i] << " ";
  }
  cout << endl;
}
