#include <bits/stdc++.h>
using namespace std;
const int inf = 0x3f3f3f3f;
const int maxn = 105;
int a[maxn];
int ans[maxn];
bool vis[maxn];
int main() {
  int n;
  while (cin >> n) {
    memset(vis, false, sizeof vis);
    int maxpos = -1, low = inf;
    int num = 0;
    for (int i = 0; i < n; i++) {
      scanf("%d", a + i);
      int temp = a[i], t = 0;
      while (temp) {
        temp /= 10;
        t++;
      }
      maxpos = max(maxpos, t);
      if (a[i] == 0) {
        ans[num++] = a[i];
        maxpos = max(maxpos, 1);
      }
    }
    for (int i = 0; i < maxpos; i++) {
      for (int j = 0; j < n; j++) {
        if (vis[j]) continue;
        int temp = a[j];
        for (int k = 0; k < i; k++) temp /= 10;
        if (temp != 0 && temp % 10 == 0) {
          temp /= 10;
          bool flag = true;
          while (temp) {
            if (temp % 10 == 0) {
              flag = false;
              break;
            }
            temp /= 10;
          }
          if (flag) {
            low = min(low, i + 1);
            ans[num++] = a[j];
            vis[j] = true;
            break;
          }
        }
      }
    }
    if (num == 0) {
      puts("1");
      printf("%d\n", a[0]);
      continue;
    }
    for (int i = 0; i < n; i++) {
      int temp = a[i], t = 0, k = 0;
      if (a[i] == 0) continue;
      while (temp) {
        if (temp % 10) k++;
        temp /= 10;
        t++;
      }
      if (t == k && k <= low) {
        ans[num++] = a[i];
        break;
      }
    }
    printf("%d\n", num);
    for (int i = 0; i < num; i++) {
      if (i == 0)
        printf("%d", ans[i]);
      else
        printf(" %d", ans[i]);
      if (i == num - 1) puts("");
    }
  }
  return 0;
}
