#P5253. [JSOI2013] 丢番图

[JSOI2013] 丢番图

Description

Consider the following Diophantine equation:

$$\frac{1}{x}~+~\frac{1}{y}~=~\frac{1}{n}~,(x,y,n~\in~\mathbb{N}^+)$$

Xiao G is very interested in the following question: for a given positive integer nn, how many essentially different solutions satisfy the equation above? For example, when n=4n=4, there are three essentially different solutions (x  y)(x~\leq~y):

15+120 = 14\frac{1}{5}+\frac{1}{20}~=~\frac{1}{4}

16+112 = 14\frac{1}{6}+\frac{1}{12}~=~\frac{1}{4}

18+18 = 14\frac{1}{8}+\frac{1}{8}~=~\frac{1}{4}

Obviously, for larger nn, it is meaningless to list all essentially different solutions. Can you help Xiao G quickly find, for a given nn, the number of essentially different solutions to the equation above?

Input Format

One line with only one integer nn.

Output Format

Output one line with one integer, representing the answer.

4
3

Hint

Constraints

For all testdata, it is guaranteed that 1n10141 \leq n \leq 10^{14}.

Translated by ChatGPT 5