import std.stdio;void main(){for(int x,k,v;~scanf("%x",&v);k+=k?putchar=x,x>>=9,-1:8)x|=v<