#include <bits/stdc++.h>
using namespace std;
string a;
long long td(char x) { return x - '0'; }
int main() {
  long long cur = 0;
  cin >> a;
  long long as[10], c[10] = {0};
  for (int i = 0; i < a.size(); ++i) {
    cur = max(cur, td(a[i]));
    as[i] = td(a[i]);
  }
  cout << cur << endl;
  for (int i = 0; i < a.size(); ++i) {
    for (int j = 1; j <= cur; ++j) {
      if (as[i] > 0) {
        c[j] = c[j] * 10 + 1;
        --as[i];
      } else {
        c[j] = c[j] * 10;
      }
    }
  }
  for (int i = 1; i <= cur; ++i) {
    cout << c[i] << " ";
  }
}
