



def 						UpperCAmelCase (    _lowerCamelCase     ):
			A				:       str														=    [True for i in range(n + 1     )]
			A				:       List[Any]														=    [i - 1 for i in range(n + 1     )]
			A				:       List[str]														=    []
			for i in range(2			,     n + 1     ):
						if is_prime[i]:
									primes.append(_lowerCamelCase     )
						for j in range(0			,     len(_lowerCamelCase     )     ):
									if i * primes[j] >= n:
												break
									A				:       List[Any]														=    False

									if i % primes[j] == 0:
												A				:       int														=    totients[i] * primes[j]
												break

									A				:       Optional[Any]														=    totients[i] * (primes[j] - 1)

			return totients


if __name__ == "__main__":
							import doctest

							doctest.testmod()




import math
from decimal import Decimal, getcontext




def 						UpperCAmelCase (    _lowerCamelCase = 400_0000     ):

			try:
						A				:       Any														=    int(_lowerCamelCase     )
			except (TypeError, ValueError):
						raise TypeError("Parameter n must be int or castable to int."     )
			if n <= 0:
						raise ValueError("Parameter n must be greater than or equal to one."     )
			A				:       int														=    100
			A				:       Tuple														=    (Decimal(5     ) ** Decimal(0.5     ) + 1) / Decimal(2     )

			A				:       str														=    (math.floor(math.log(n * (phi + 2)			,     _lowerCamelCase     ) - 1     ) // 3) * 3 + 2
			A				:       Optional[int]														=    Decimal(round(phi ** Decimal(index + 1     )     )     ) / (phi + 2)
			A				:       str														=    num // 2
			return int(_lowerCamelCase     )


if __name__ == "__main__":
							print(F"""{solution() = }""")