
'''simple docstring'''






import math
import sys


def 	_A  (					A__   ):






 """simple docstring"""



 if number != int(snake_case_   ):
  raise ValueError('''the value of input must be a natural number'''   )
 if number < 0:
  raise ValueError('''the value of input must not be a negative number'''   )
 if number == 0:
  return 1
 __lowercase													=				[-1] * (number + 1)
 __lowercase													=				0
 for i in range(1  ,       number + 1   ):
  __lowercase													=				sys.maxsize
  __lowercase													=				int(math.sqrt(snake_case_   )   )
  for j in range(1  ,       root + 1   ):
   __lowercase													=				1 + answers[i - (j**2)]
   __lowercase													=				min(snake_case_  ,       snake_case_   )
  __lowercase													=				answer
 return answers[number]


if __name__ == "__main__":
 import doctest

 doctest.testmod()




'''simple docstring'''






def 	_A  (					):






 """simple docstring"""



 for n in range(1  ,       1000000   ):
  yield n * (n + 1) // 2


def 	_A  (					A__   ):






 """simple docstring"""



 __lowercase													=				1
 __lowercase													=				2
 while i * i <= n:
  __lowercase													=				0
  while n % i == 0:
   n //= i
   multiplicity += 1
  divisors_count *= multiplicity + 1
  i += 1
 if n > 1:
  divisors_count *= 2
 return divisors_count


def 	_A  (					):






 """simple docstring"""



 return next(i for i in triangle_number_generator() if count_divisors(A__   ) > 500   )


if __name__ == "__main__":
 print(solution())

