#include <bits/stdc++.h>
using namespace std;
int main() {
  long n, m, val, i, j = 0, sum = 0, k = 0;
  vector<long> toys;
  vector<long> selected;
  cin >> n >> m;
  for (i = 0; i < n; i++) {
    cin >> val;
    toys.push_back(val);
  }
  sort(toys.begin(), toys.end());
  for (i = 0; i < 1000000000; i++) {
    if (j < (long)toys.size()) {
      if (toys[j] == (i + 1)) {
        j++;
      } else {
        if (sum + i + 1 <= m) {
          selected.push_back(i + 1);
          sum += i + 1;
          k++;
        } else {
          break;
        }
      }
    } else if (sum + i + 1 <= m) {
      selected.push_back(i + 1);
      sum += i + 1;
      k++;
    } else {
      break;
    }
  }
  cout << k << endl;
  for (auto t : selected) {
    cout << t << " ";
  }
  cout << endl;
  return 0;
}
