#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 5;
long long b[N], a[N];
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  long long n, k, s;
  cin >> n >> k >> s;
  for (int i = 1; i <= k; i++) {
    a[i] = s;
  }
  if (n - k < s) {
    for (int i = k + 1; i <= n; i++) {
      a[i] = 1;
    }
  } else {
    int t = 1, flag = 1;
    for (int i = k + 1; i <= n; i++) {
      if (flag && (i - k) % s == 0) {
        flag = 0;
        a[i] = ++t;
      } else
        a[i] = t;
    }
  }
  for (int i = 1; i <= n; i++) {
    cout << a[i] << " ";
  }
  return 0;
}
