#include <bits/stdc++.h>
using namespace std;
int r;
int Abs(int x) {
  if (x < 0) return -x;
  return x;
}
int Min(int a, int b) {
  if (a < b) return a;
  return b;
}
int getNearest(int n) {
  int rs = 0;
  int t = 0;
  int cnt = 1;
  while (n != 0) {
    int p = n % 10;
    if (p != 0) rs += cnt;
    cnt *= 10;
    n /= 10;
  }
  return rs;
}
int main() {
  int n;
  cin >> n;
  vector<int> res;
  while (n != 0) {
    int p = getNearest(n);
    n -= p;
    res.push_back(p);
  }
  cout << res.size() << endl;
  for (int i = 0; i < res.size(); i++) cout << res[i] << " ";
}
