#include<bits/stdc++.h> using namespace std; int main(){ int n,a[10],k=0; cin>>n; while(n!=0){ a[++k]=n%10; n/=10; } cout<<k<<endl; for(int i=k;i>=1;i--) cout<<a[i]<<endl; return 0; }