#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<int> a;
  while (n) {
    int x = n, p = 1, m = 0;
    while (x) {
      if (x % 10) m += p;
      x /= 10;
      p *= 10;
    }
    n -= m;
    a.push_back(m);
  }
  cout << a.size() << endl;
  for (int &i : a) cout << i << " ";
}
