import math



n = int(eval(input()))

ans = 0

SQRT = int(n ** 0.5)

for m in range(1,int(n ** 0.5) + 1):

    ans += m * (m + int(n/m)) * (int(n/m) + 1 - m)

ans -= SQRT * (SQRT+1) * (2*SQRT+1) // 6

print(ans)

n = int(eval(input()))

ans = 0

SQRT = int(n ** 0.5)

for m in range(1,SQRT + 1):

    b = int(n/m)

    ans += m * (m + b) * (b + 1 - m)

ans -= SQRT * (SQRT+1) * (2*SQRT+1) // 6

print(ans)
import math

n = int(eval(input()))
ans = 0
SQRT = int(n**0.5)
for m in range(1, int(n**0.5) + 1):
    ans += m * (m + int(n / m)) * (int(n / m) + 1 - m)
ans -= SQRT * (SQRT + 1) * (2 * SQRT + 1) // 6
print(ans)

n = int(eval(input()))
ans = 0
SQRT = int(n**0.5)
for m in range(1, SQRT + 1):
    b = int(n / m)
    ans += m * (m + b) * (b + 1 - m)
ans -= SQRT * (SQRT + 1) * (2 * SQRT + 1) // 6
print(ans)

-import math - -for m in range(1, int(n**0.5) + 1): -    ans += m * (m + int(n / m)) * (int(n / m) + 1 - m) +for m in range(1, SQRT + 1): +    b = int(n / m) +    ans += m * (m + b) * (b + 1 - m)