Mysterious equation#6286

Mysterious equation

1 second
128 megabytes
Easy

Little Vasya is very fond of equations. Once his sight caught the equation x + y + xy = n. Vasya wants to know the number of pairs of non-negative integers and , that are the solutions of this equation.

Input

One integer n~(0 \le n \le 10^9).

Output

Print the number of pairs of solutions.

Examples

Below given all the solutions of equation x + y + xy = 5:

  • (x, y) = (0, 5)

  • (x, y) = (1, 2)

  • (x, y) = (2, 1)

  • (x, y) = (5, 0)

Example 1

Loading
Loading

Example 2

Loading
Loading