#include <bits/stdc++.h>
using namespace std;
const int N = 2e3 + 5;
int a[N], cnt[N];
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &a[i]);
    if (a[i] <= m) cnt[a[i]]++;
  }
  int avg = n / m, ans = 0;
  printf("%d ", avg);
  int k = 1;
  while (k <= m && cnt[k] >= avg) k++;
  for (int i = 1; i <= n && k <= m; i++) {
    if (a[i] > m) {
      a[i] = k;
      cnt[k]++;
      ans++;
      while (k <= m && cnt[k] >= avg) k++;
    }
  }
  for (int k = 1; k <= m; k++) {
    if (cnt[k] < avg) {
      for (int i = 1; i <= n; i++) {
        if (cnt[a[i]] > avg) {
          cnt[a[i]]--;
          ans++;
          a[i] = k;
          if (++cnt[k] == avg) break;
        }
      }
    }
  }
  printf("%d\n", ans);
  for (int i = 1; i <= n; i++) printf("%d%c", a[i], (i == n) ? '\n' : ' ');
  return 0;
}
