#include <bits/stdc++.h>
using namespace std;
int a[100111];
vector<int> presents;
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  for (int i = 0; i < n; i++) scanf("%d", &a[i]);
  a[n++] = 1e9 + 1;
  sort(a, a + n);
  int j = 1;
  int s = 0;
  for (int i = 0; i < n; i++) {
    while (j < a[i] && s + j <= m) {
      presents.push_back(j);
      s += j;
      j++;
    }
    j = a[i] + 1;
  }
  printf("%d\n", presents.size());
  for (int i = 0; i < presents.size(); i++) printf("%d ", presents[i]);
  printf("\n");
}
