function pohe(x) print(dec(x)) end s = readline(STDIN) a=parse(BigInt,s,2) print(a)