#include <bits/stdc++.h>
using namespace std;
int has[100000];
int mom[100000];
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  int i;
  for (i = 0; i < n; i++) scanf("%d", &has[i]);
  sort(has, has + n);
  int j, sum = 0, cnt = 0;
  for (j = 1, i = 0;; j++) {
    if (j == has[i])
      i++;
    else {
      if (j + sum <= m) {
        mom[cnt++] = j;
        sum += j;
      } else
        break;
    }
  }
  printf("%d\n", cnt);
  if (cnt) {
    for (i = 0; i < cnt - 1; i++) printf("%d ", mom[i]);
    printf("%d\n", mom[i]);
  }
  return 0;
}
