Magic. Revelation.#5727

Magic. Revelation.

0.5 seconds
16 megabytes
Medium

The magician in the mask: "Name two whole numbers greater than ten that do not contain zeros."

Audience: "27 and 159."

The magician in the mask: "Good, now rearrange the digits in each of these numbers in any way and use a calculator to find the product of the new numbers. Done? Cross out any non-zero digit from the result and name the remaining digits in any order."

Audience: "329" (The numbers 27 and 159 were multiplied, resulting in 4293.)

The magician in the mask: "You crossed out the digit 4."

Input

The first line of the input file contains the first named number (10 < A < 10^{100}), the second line contains the second number (10 < B < 10^{100}), and the third line contains the digits of the result in any order after a digit is crossed out.

Output

Output the digit that was crossed out from the result.

Examples

Example 1

Loading
Loading