//AC代码。。。表示很晕
#include <iostream>
using namespace std;
int a[],b[];
int main()
{
int n,m,cnt;
cin >> n >> m;
int t = n/m;
int t2 = n%m;
if(n%m == ) cnt = t;
else cnt = t+;
for(int i=; i<n; ++i)
{
cin >> a[i];
if(a[i] <= m) ++b[a[i]];
if(a[i] <= m && t2 > && b[a[i]] == cnt) --t2;
}
int f = ;
int ans = ;
if(t2 == ) cnt = t;
//cout << cnt << endl;
for(int i=; i<n; ++i)
{
if(a[i] > m ||(a[i] <=m && b[a[i]] > cnt))
{
while(f <= m)
{
//cout <<"test" << f << " " << cnt << endl;
if(b[f] < t) break;
++f;
}
if(f <= m)
{
++ans;
if(a[i] <= m)
--b[a[i]];
a[i] = f;
++b[f];
//cout <<t2 << "bf " << b[f] <<" " << cnt << endl;
if(t2 > && b[f] == cnt )
if((--t2) == ) cnt = t;
if(a[i] <= m && t2 > && b[a[i]] == cnt)
if((--t2) == ) cnt = t;
}
}
}
cout << t << " " << ans << endl;
for(int i=; i<n; ++i)
if(i == )
cout << a[i];
else
cout << " " << a[i];
cout << endl;
return ;
}