main(c,v)char*c;{for(;gets(v);){c=rindex(v,48);c=c?c:v;while(*c)*c++^=1;puts();}}