#include <bits/stdc++.h>
using namespace std;
const int N = (int)1e7 + 5;
int f[N], a[N];
pair<int, int> b[N];
int n, m, k;
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  ;
  cin >> n >> m >> k;
  for (int i = 0; i < n; i++) cin >> a[i];
  for (int i = 0; i < m; i++) {
    cin >> b[i].first;
    b[i].second = i + 1;
  }
  sort(a, a + n);
  sort(b, b + m);
  stack<int> stk;
  int day = a[n - 1];
  for (int i = n - 1; i >= 0; i--) {
    day = min(a[i], day);
    while (day >= 0 && f[day] >= k) day--;
    if (day < 0) {
      cout << -1 << '\n';
      return 0;
    }
    f[day]++;
  }
  vector<int> ans;
  day = b[m - 1].first;
  for (int i = m - 1; i >= 0; i--) {
    day = min(b[i].first, day);
    while (day >= 0 && f[day] >= k) day--;
    if (day < 0) break;
    f[day]++;
    ans.push_back(b[i].second);
  }
  cout << (int)ans.size() << '\n';
  for (auto &x : ans) cout << x << " ";
  cout << '\n';
  return 0;
}
