


"""simple docstring"""






from collections.abc import Sequence


def __lowercase     (      lowerCamelCase_  :      Sequence[float]						,					lowerCamelCase_  :      float  ):
				return sum(c * (x**i) for i, c in enumerate(lowerCamelCase_  )  )


def __lowercase     (      lowerCamelCase_  :      Sequence[float]						,					lowerCamelCase_  :      float  ):
				SCREAMING_SNAKE_CASE__     							=				0.0
				for coeff in reversed(lowerCamelCase_  ):
								SCREAMING_SNAKE_CASE__     							=				result * x + coeff
				return result


if __name__ == "__main__":
	_lowerCamelCase     =  (0.0, 0.0, 5.0, 9.3, 7.0)
	_lowerCamelCase     =  10.0
	print(evaluate_poly(poly, x))
	print(horner(poly, x))




"""simple docstring"""






from math import sqrt


def __lowercase     (      lowerCamelCase_  :      int  ):
				SCREAMING_SNAKE_CASE__     							=				0
				for i in range(1						,					int(sqrt(lowerCamelCase_  ) + 1  )  ):
								if n % i == 0 and i != sqrt(lowerCamelCase_  ):
												total += i + n // i
								elif i == sqrt(lowerCamelCase_  ):
												total += i
				return total - n


def __lowercase     (      lowerCamelCase_  :      int = 10000  ):
				SCREAMING_SNAKE_CASE__     							=				sum(
				    i
				    for i in range(1						,					lowerCamelCase_  )
				    if sum_of_divisors(sum_of_divisors(lowerCamelCase_  )  ) == i and sum_of_divisors(lowerCamelCase_  ) != i  )
				return total


if __name__ == "__main__":
	print(solution(int(str(input()).strip())))
