Number Theory#1564

Number Theory

1 second
128 megabytes
Very easy

For the given positive integer , find the number of integers such that 1 \le m \le n, \gcd(m, n) \ne 1, and \gcd(m, n) \ne m. Here, stands for "greatest common divisor".

Input

Each line contains one positive integer (0 < n < 2^{31}).

Output

For each , output the number of integers that satisfy the conditions, one per line.

Examples

Example 1

Loading
Loading