#abc306b. [abc306_b]Base 2
[abc306_b]Base 2
Problem Statement
You are given a sequence of length consisting of and .
Find .
Constraints
- is or .
Input
The input is given from Standard Input in the following format:
Output
Print the answer as an integer.
Sample Input 1
1 0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Sample Output 1
13
$A_0 2^0 + A_1 2^1 + \\dots + A_{63} 2^{63} = 2^0 + 2^2 + 2^3 = 13$.
Sample Input 2
1 0 1 0 1 0 0 0 0 1 0 0 1 1 0 1 1 1 1 0 0 0 1 0 0 1 1 1 1 1 1 0 0 0 0 1 0 1 0 1 0 1 1 1 1 0 0 1 1 0 0 0 0 1 0 1 0 1 0 1 0 0 0 0
Sample Output 2
766067858140017173