# Answer: 16.

## Conditions and answers to the problems of the final stage of the 2012-13 academic year

#
Problem 6.

It is known that three numbers $a_{1}, a_{2}, a_{3}$ were obtained as follows. First, a natural number $A$ was chosen and the numbers $A_{1}=[A]_{16}, A_{2}=$ $[A / 2]_{16}, A_{3}=[A / 4]_{16}$ were found, where $[X]_{16}$ is the remainder of the integer part of the number $X$ divided by 16 (for example, $[53 / 2]_{16}=10$). Then an integer $B$ was chosen such that 0 $\leq \mathrm{B} \leq 15$. The numbers $A_{1}, A_{2}, A_{3}$ and $B$ are written in binary, i.e., each is represented as a string of 0s and 1s of length 4, adding the necessary number of zeros on the left. We agree to add such strings symbol by symbol "in a column" without carrying to the next digit according to the rule: $1+1=0+0=0$ and $0+1=1+0=0$, and denote the operation of symbol-by-symbol addition by the symbol $\diamond$. For example, $3 \diamond 14=(0011) \diamond$ $(1110)=(1101)=13$. Let $a_{1}=A_{1} \diamond B, a_{2}=A_{2} \diamond B, a_{3}=A_{3} \diamond B$. Find the sum of all possible values of the number $a_{3}$, given that $a_{1}=2, a_{2}=$ 9. Choose the correct answer:

#