#include <iostream>
#include<string.h>
using namespace std;
int main()
{ char a[21],a1[21];
int i;
cin>>a;
for(i=0;i<strlen(a);i++)
{ if(a[i]==a[i+1])
{ i++;
strcpy(a+i,a+i+1);
strcpy(a1,a);
strcpy(a1+i,a1+i+1);
cout<<a1<<endl;
}
else
{strcpy(a1,a);
strcpy(a1+i,a1+i+1);
cout<<a1<<" ";
}
}
}