Result [link]

AC

Code [DL]

(de f (x b s)
	(if (= x 0) s (f (/ x 10) (* 2 b) (+ (* b (% x 10)) s))))

(de main ()
	(let (n (read))
		(prinl (f n 1 0))
	)
)

(in NIL (main))

stdin

1101101011110110111010010111110111100010100100000100010100100111100110011001110010110100101111001110

stdout

1084259688419801060569760091086

stderr

strace