Sticks box
The box contains sticks, which need to be divided between friends Renato, Gustavo and Bruno, for a school job. Each friend must earn at least 1 (one) toothpick. The teacher will determine the maximum number of sticks that each one can earn.
In this task, given and , your program must calculate how many different ways there are to divide all sticks among the three friends. For example, for ; if , then there are zero ways of dividing because the sum of the numbers of Renato, Gustavo and Bruno's toothpicks would be at most 45, only it must always be ; but if , then there would be six different ways:
Input
The entry consists of only one line with two natural numbers and , indicating respectively the number of sticks in the box and the maximum amount that each friend can win.

Figure 1
Output
Your program should write a single line in the output, containing a single integer: how many different ways are there to divide sticks among the three friends.
Constraints
Input Samples | Output Samples |
---|---|
100 15
|
0
|
100000 98765
|
4997567718
|