#include<bits/stdc++.h>
using namespace std;
string s;
int a[100001];
main()
{
    int i;
    cin>>s;
    for(i=0;i<s.length();i++)
    {
        a[i]=s[i]-'0';
        cout<<a[i]<< " ";
    }
    cout<<"1";
}