#include <bits/stdc++.h>
using namespace std;
const long long N = 2e5 + 10;
int main() {
  long long n, m, k;
  cin >> n >> m;
  unordered_map<long long, long long> vis;
  for (long long i = 0; i < n; i++) {
    long long x;
    cin >> x;
    vis[x] = 1;
  }
  long long sum = 0, cnt = 0;
  vector<long long> vec;
  for (long long i = 1;; i++) {
    if (vis[i] == 0) {
      sum += i;
      if (sum <= m) {
        cnt++;
        vec.push_back(i);
      }
      if (sum > m) break;
    }
  }
  cout << cnt << "\n";
  for (auto x : vec) {
    cout << x << " ";
  }
  cout << "\n";
}
