


import importlib.metadata
from typing import Union

from packaging.version import Version, parse

from .constants import STR_OPERATION_TO_FUNC


snake_case							:	Tuple					      =				parse(importlib.metadata.version('''torch'''))






def 							__lowercase       (			__lowerCAmelCase							:    Union[str, Version] ,   __lowerCAmelCase							:    str ,   __lowerCAmelCase							:    str       ):
							if operation not in STR_OPERATION_TO_FUNC.keys():
														raise ValueError(F'`operation` must be one of {list(STR_OPERATION_TO_FUNC.keys()       )}, received {operation}'       )
							a__					=					STR_OPERATION_TO_FUNC[operation]
							if isinstance(__lowerCAmelCase ,   __lowerCAmelCase       ):
														a__					=					parse(importlib.metadata.version(__lowerCAmelCase       )       )
							return operation(__lowerCAmelCase ,   parse(__lowerCAmelCase       )       )






def 							__lowercase       (			__lowerCAmelCase							:    str ,   __lowerCAmelCase							:    str       ):
							return compare_versions(__lowerCAmelCase ,   __lowerCAmelCase ,   __lowerCAmelCase       )








from math import ceil, sqrt






def 							__lowercase       (			__lowerCAmelCase							:    int = 1_0_0_0_0_0_0       ):
							a__					=					0

							for outer_width in range(3 ,   (limit // 4) + 2       ):
														if outer_width**2 > limit:
																					a__					=					max(ceil(sqrt(outer_width**2 - limit       )       ) ,   1       )
														else:
																					a__					=					1
														if (outer_width - hole_width_lower_bound) % 2:
																					hole_width_lower_bound += 1

														answer += (outer_width - hole_width_lower_bound - 2) // 2 + 1

							return answer


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




