#include <bits/stdc++.h>
using namespace std;
int n, m, avg;
vector<int> a;
map<int, vector<int> > cnt;
vector<int> U;
void input() {
  scanf("%d%d", &n, &m);
  avg = n / m;
  a.resize(n);
  for (int i = 0; i < n; i++) {
    scanf("%d", &a[i]);
    cnt[a[i]].push_back(i);
  }
}
void find_can_use() {
  for (auto pp : cnt) {
    int x = pp.first;
    auto &vec = pp.second;
    if (x <= m && vec.size() > avg) {
      while (vec.size() > avg) {
        U.push_back(vec.back());
        vec.pop_back();
      }
    }
    if (x > m) {
      while (vec.size() > 0) {
        U.push_back(vec.back());
        vec.pop_back();
      }
    }
  }
}
int change = 0;
void solve() {
  for (int i = 1; i <= m; i++)
    while (cnt[i].size() < avg) {
      int u = U.back();
      U.pop_back();
      a[u] = i;
      change++;
      cnt[i].push_back(u);
    }
}
int main() {
  input();
  find_can_use();
  solve();
  printf("%d %d\n", avg, change);
  for (auto x : a) printf("%d ", x);
}
