#ARC112B. [ARC112B] -- - B

[ARC112B] -- - B

Score : 400400 points

Problem Statement

Snuke has come to Seisu-ya (integer shop) with an integer BB in his hand. In Seiyu-ya, you can exchange your integer for another integer by paying money.

More specifically, you can use the following two services any number of times in any order:

  • Pay 11 yen (the currency of Japan) to multiply your integer by 1-1.
  • Pay 22 yen to subtract 11 from your integer.

How many integers are there that Snuke can get for at most CC yen?

Constraints

  • 1018B1018-10^{18}\le B \le 10^{18}
  • 1C10181\le C \le 10^{18}
  • All values in input are integers.

Input

Input is given from Standard Input in the following format:

BB CC

Output

Print the answer.

11 2
3

There are three numbers that Snuke can get: 11-11, 1010, and 1111, as follows:

  • by doing nothing, he can get 1111 for 00 yen;
  • by multiplying 1111 by 1-1, he can get 11-11 for 11 yen;
  • by subtracting 11 from 1111, he can get 1010 for 22 yen.
0 4
4

There are four numbers that Snuke can get: 2-2, 1-1, 00, and 11, as follows:

  • by doing nothing, he can get 00 for 00 yen;
  • by subtracting 11 from 00, he can get 1-1 for 22 yen;
  • by subtracting 11 from 00 and then multiplying by 1-1, he can get 11 for 33 yen;
  • by subtracting 11 from 00 and then subtracting 11 again, he can get 2-2 for 44 yen.
112 20210213
20210436
-211 1000000000000000000
1000000000000000422