eolymp
bolt
Try our new interface for solving problems
Problems

LCM Cardinality

LCM Cardinality

A pair of numbers has a unique \textbf{LCM} but a single number can be the \textbf{LCM} of more than one possible pairs. For example \textbf{12} is the \textbf{LCM} of \textbf{(1, 12)}, \textbf{(2, 12)}, \textbf{(3,4)} etc. For a given positive integer \textbf{N,} the number of different integer pairs with \textbf{LCM} is equal to \textbf{N} can be called the \textbf{LCM} cardinality of that number \textbf{N}. In this problem your job is to find out the \textbf{LCM} cardinality of a number. \InputFile The input file contains at most \textbf{101} lines of inputs. Each line contains an integer \textbf{N} (\textbf{0} < \textbf{N} ≤ \textbf{2·10^9}). Input is terminated by a line containing a single zero. This line should not be processed. \OutputFile For each line of input except the last one produce one line of output. This line contains two integers \textbf{N} and \textbf{C}. Here \textbf{N} is the input number and \textbf{C} is its cardinality. These two numbers are separated by a single space.
Time limit 1 second
Memory limit 64 MiB
Input example #1
2
12
24
101101291
0
Output example #1
2 2
12 8
24 11
101101291 5