#include <bits/stdc++.h>
using namespace std;
const int INF = 1000 * 1000 * 1000 + 7;
const double EPS = 1e-9;
const double PI = acos(-1.0);
template <class T>
int chmin(T &t, T f) {
  return (t > f) ? (t = f, 1) : 0;
}
template <class T>
int chmax(T &t, T f) {
  return (t < f) ? (t = f, 1) : 0;
}
inline int getint() {
  int a;
  return scanf("%d", &a) ? a : (fprintf(stderr, "trying to read\n"), -1);
}
inline double getdouble() {
  double a;
  return scanf("%lf", &a) ? a : (fprintf(stderr, "trying to read\n"), -1);
}
int process(int first) {
  int ret = 0, tmp = 1;
  while (first) {
    if (first % 10) ret += tmp;
    first /= 10;
    tmp *= 2;
  }
  return ret;
}
void myCode() {
  vector<int> ret;
  int n = getint(), a1 = -1, a2 = -1, a3 = -1;
  for (int i = (int)0; i < (int)n; i++) {
    int first = getint();
    if (first == 0) ret.push_back(0);
    if (first == 100) ret.push_back(100);
    if (process(first) == 1) a1 = first;
    if (process(first) == 2) a2 = first;
    if (process(first) == 3) a3 = first;
  }
  if (a1 != -1 && a2 != -1) {
    ret.push_back(a1);
    ret.push_back(a2);
  } else if (a3 != -1) {
    ret.push_back(a3);
  } else if (a1 != -1) {
    ret.push_back(a1);
  } else if (a2 != -1) {
    ret.push_back(a2);
  }
  sort((ret).begin(), (ret).end());
  ret.resize(unique((ret).begin(), (ret).end()) - ret.begin());
  printf("%d\n", ((int)(ret).size()));
  for (int i = (int)0; i < (int)((int)(ret).size()); i++)
    printf("%d%c", ret[i], i == ((int)(ret).size()) - 1 ? '\n' : ' ');
}
int main() {
  myCode();
  return 0;
}
