Niuniu likes calculating sums. He has recently learnt how to calculate sums using various methods. Here is one of them:
Note that [x] is 1 when x is true and 0 when x is false.
Can you calculate the sum? The answer may be large, so please calculate the sum modulo a given number K.
The only line contains three integers N, M, K.1 ≤ N ≤ 109, 1 ≤ M ≤ 106, 1 ≤ K ≤ 109
Print a single line with one number, which is the answer.