integer(8) :: i,j,k,m,n,nn,ans(1000)=0,ii
read*, n

if(n==0)then
  print"(i0)",0
  stop
endif

nn=n
i = 1
ii = 1

do while(nn/=0)
  if(mod(nn,-2*ii)/= 0)then
    ans(i) = 1
    nn = nn - ii
  endif
  i=i+1
  ii = ii * (-2)
end do

print"(1000(I0))", ans(i-1:1:-1)

end