




def 		_A(       UpperCamelCase__							:			int = 5000_0000				)    -> int:
							'''simple docstring'''


							__lowercase      =    set()
							__lowercase      =    int((limit - 24) ** (1 / 2)				)

							__lowercase      =    set(range(3				,       prime_square_limit + 1				,       2				)				)
							primes.add(2				)
							for p in range(3				,       prime_square_limit + 1				,       2				):
														if p not in primes:
																					continue
														primes.difference_update(set(range(p * p				,       prime_square_limit + 1				,       UpperCamelCase__				)				)				)

							for primea in primes:
														__lowercase      =    primea * primea
														for primea in primes:
																					__lowercase      =    primea * primea * primea
																					if square + cube >= limit - 16:
																												break
																					for primea in primes:
																												__lowercase      =    primea * primea * primea * primea
																												__lowercase      =    square + cube + tetr
																												if total >= limit:
																																			break
																												ret.add(UpperCamelCase__				)

							return len(UpperCamelCase__				)


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












from __future__ import annotations







def 		_A(       UpperCamelCase__							:			list[int]				,       UpperCamelCase__							:			list[int]				,       UpperCamelCase__							:			int				)    -> tuple[float, list[float]]:
							'''simple docstring'''


							__lowercase      =    list(range(len(UpperCamelCase__				)				)				)
							__lowercase      =    [v / w for v, w in zip(UpperCamelCase__				,       UpperCamelCase__				)]
							index.sort(key=lambda UpperCamelCase__				: ratio[i]				,       reverse=UpperCamelCase__				)

							__lowercase      =    0
							__lowercase      =    [0] * len(UpperCamelCase__				)
							for i in index:
														if weight[i] <= capacity:
																					__lowercase      =    1
																					max_value += value[i]
																					capacity -= weight[i]
														else:
																					__lowercase      =    capacity / weight[i]
																					max_value += value[i] * capacity / weight[i]
																					break

							return max_value, fractions


if __name__ == "__main__":
			import doctest

			doctest.testmod()






