




def       _a (		SCREAMING_SNAKE_CASE_				:							float	):
					return -num if num < 0 else num







def       _a (		SCREAMING_SNAKE_CASE_				:							list[int]	):
					if len(SCREAMING_SNAKE_CASE_	) == 0:
										raise ValueError("abs_min() arg is an empty sequence"	)
					__lowerCAmelCase							  =			x[0]
					for i in x:
										if abs_val(SCREAMING_SNAKE_CASE_	) < abs_val(SCREAMING_SNAKE_CASE_	):
															__lowerCAmelCase							  =			i
					return j







def       _a (		SCREAMING_SNAKE_CASE_				:							list[int]	):
					if len(SCREAMING_SNAKE_CASE_	) == 0:
										raise ValueError("abs_max() arg is an empty sequence"	)
					__lowerCAmelCase							  =			x[0]
					for i in x:
										if abs(SCREAMING_SNAKE_CASE_	) > abs(SCREAMING_SNAKE_CASE_	):
															__lowerCAmelCase							  =			i
					return j







def       _a (		SCREAMING_SNAKE_CASE_				:							list[int]	):
					if len(SCREAMING_SNAKE_CASE_	) == 0:
										raise ValueError("abs_max_sort() arg is an empty sequence"	)
					return sorted(SCREAMING_SNAKE_CASE_ , key=SCREAMING_SNAKE_CASE_	)[-1]







def       _a (		):
					assert abs_val(0	) == 0
					assert abs_val(34	) == 34
					assert abs_val(-10_00_00_00_00_00	) == 10_00_00_00_00_00

					__lowerCAmelCase							  =			[-3, -1, 2, -11]
					assert abs_max(SCREAMING_SNAKE_CASE_	) == -11
					assert abs_max_sort(SCREAMING_SNAKE_CASE_	) == -11
					assert abs_min(SCREAMING_SNAKE_CASE_	) == -1


if __name__ == "__main__":
					import doctest

					doctest.testmod()

					test_abs_val()
					print(abs_val(-34))  # --> 34










from __future__ import annotations

from pathlib import Path







def       _a (		SCREAMING_SNAKE_CASE_				:							tuple[int, int] , SCREAMING_SNAKE_CASE_				:							tuple[int, int]	):
					return pointa[0] * pointa[1] - pointa[1] * pointa[0]







def       _a (		SCREAMING_SNAKE_CASE_				:							int , SCREAMING_SNAKE_CASE_				:							int , SCREAMING_SNAKE_CASE_				:							int , SCREAMING_SNAKE_CASE_				:							int , SCREAMING_SNAKE_CASE_				:							int , SCREAMING_SNAKE_CASE_				:							int	):
					__lowerCAmelCase							  =			(xa, ya)
					__lowerCAmelCase							  =			(xa - xa, ya - ya)
					__lowerCAmelCase							  =			(xa - xa, ya - ya)
					__lowerCAmelCase							  =			-vector_product(SCREAMING_SNAKE_CASE_ , SCREAMING_SNAKE_CASE_	) / vector_product(
					    SCREAMING_SNAKE_CASE_ , SCREAMING_SNAKE_CASE_	)
					__lowerCAmelCase							  =			+vector_product(SCREAMING_SNAKE_CASE_ , SCREAMING_SNAKE_CASE_	) / vector_product(
					    SCREAMING_SNAKE_CASE_ , SCREAMING_SNAKE_CASE_	)

					return a > 0 and b > 0 and a + b < 1







def       _a (		SCREAMING_SNAKE_CASE_				:							str = "p102_triangles.txt"	):
					__lowerCAmelCase							  =			Path(SCREAMING_SNAKE_CASE_	).parent.joinpath(SCREAMING_SNAKE_CASE_	).read_text(encoding="utf-8"	)

					__lowerCAmelCase							  =			[]
					for line in data.strip().split("\n"	):
										triangles.append([int(SCREAMING_SNAKE_CASE_	) for number in line.split(","	)]	)

					__lowerCAmelCase							  =			0
					__lowerCAmelCase							  =			42

					for triangle in triangles:
										ret += contains_origin(*SCREAMING_SNAKE_CASE_	)

					return ret


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




