



'''simple docstring'''

from decimal import Decimal, getcontext
from math import ceil, factorial



def 					__lowerCamelCase					(				lowerCAmelCase_  )      ->				str:

		if not isinstance(lowerCAmelCase_						,      lowerCAmelCase_  ):
				raise TypeError('Undefined for non-integers'  )
		elif precision < 1:
				raise ValueError('Undefined for non-natural numbers'  )

		_a					:				Tuple				=							precision
		_a					:				int				=							ceil(precision / 14  )
		_a					:				List[Any]				=							426880 * Decimal(10005  ).sqrt()
		_a					:				Any				=							1
		_a					:				Tuple				=							13591409
		_a					:				Optional[Any]				=							Decimal(lowerCAmelCase_  )
		for k in range(1						,      lowerCAmelCase_  ):
				_a					:				List[Any]				=							factorial(6 * k  ) // (factorial(3 * k  ) * factorial(lowerCAmelCase_  ) ** 3)
				linear_term += 545140134
				exponential_term *= -262537412640768000
				partial_sum += Decimal(multinomial_term * linear_term  ) / exponential_term
		return str(constant_term / partial_sum  )[:-1]


if __name__ == "__main__":
							__lowerCAmelCase						      =       50
							print(f"""The first {n} digits of pi is: {pi(n)}""")









'''simple docstring'''

from math import sqrt



def 					__lowerCamelCase					(				lowerCAmelCase_  )      ->				int:
		_a					:				Dict				=							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 					__lowerCamelCase					(				lowerCAmelCase_ = 10000  )      ->				int:
		_a					:				Union[str, Any]				=							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())))




