Codeforces Round 520 (Div. 2)
D
Fun with Integers
Codeforces
1800
原题
← CE →
翻译中…

You are given a positive integer $n$ greater or equal to $2$. For every pair of integers $a$ and $b$ ($2 \le |a|, |b| \le n$), you can transform $a$ into $b$ if and only if there exists an integer $x$ such that $1 \lt |x|$ and ($a \cdot x = b$ or $b \cdot x = a$), where $|x|$ denotes the absolute value of $x$.

翻译中…

After such a transformation, your score increases by $|x|$ points and you are not allowed to transform $a$ into $b$ nor $b$ into $a$ anymore.

翻译中…

Initially, you have a score of $0$. You can start at any integer and transform it as many times as you like. What is the maximum score you can achieve?

翻译中…

Input

翻译中…

A single line contains a single integer $n$ ($2 \le n \le 100\,000$) — the given integer described above.

翻译中…

Output

翻译中…

Print an only integer — the maximum score that can be achieved with the transformations. If it is not possible to perform even a single transformation for all possible starting integers, print $0$.

翻译中…

Note

翻译中…

In the first example, the transformations are $2 \rightarrow 4 \rightarrow (-2) \rightarrow (-4) \rightarrow 2$.

翻译中…

In the third example, it is impossible to perform even a single transformation.

翻译中…

样例

Input #1
4
Output #1
8
InputCopy OutputCopy
Input #2
6
Output #2
28
InputCopy OutputCopy
Input #3
2
Output #3
0
InputCopy OutputCopy
题目信息
题号
1062D
时间限制
2 s
内存限制
256 MB
标签
DFS 及类似
图论
模拟
数学

题面与样例版权归 Codeforces 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。