






from __future__ import annotations

from pathlib import Path


def      lowerCamelCase__	(   lowercase  ,   lowercase ):

  """simple docstring"""






  return pointa[0] * pointa[1] - pointa[1] * pointa[0]


def      lowerCamelCase__	(   lowercase  ,   lowercase  ,   lowercase  ,   lowercase  ,   lowercase  ,   lowercase ):

  """simple docstring"""






  SCREAMING_SNAKE_CASE				:					List[Any]		  =			(xa, ya)
  SCREAMING_SNAKE_CASE				:					Any		  =			(xa - xa, ya - ya)
  SCREAMING_SNAKE_CASE				:					List[Any]		  =			(xa - xa, ya - ya)
  SCREAMING_SNAKE_CASE				:					str		  =			-vector_product(__UpperCAmelCase  ,   __UpperCAmelCase ) / vector_product(
      __UpperCAmelCase  ,   __UpperCAmelCase )
  SCREAMING_SNAKE_CASE				:					Optional[int]		  =			+vector_product(__UpperCAmelCase  ,   __UpperCAmelCase ) / vector_product(
      __UpperCAmelCase  ,   __UpperCAmelCase )

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


def      lowerCamelCase__	(   lowercase = "p102_triangles.txt" ):

  """simple docstring"""






  SCREAMING_SNAKE_CASE				:					Any		  =			Path(__UpperCAmelCase ).parent.joinpath(__UpperCAmelCase ).read_text(encoding="utf-8" )

  SCREAMING_SNAKE_CASE				:					List[Any]		  =			[]
  for line in data.strip().split("\n" ):
    triangles.append([int(__UpperCAmelCase ) for number in line.split("," )] )

  SCREAMING_SNAKE_CASE				:					str		  =			0
  SCREAMING_SNAKE_CASE				:					Optional[int]		  =			42

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

  return ret


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











from __future__ import annotations

from pathlib import Path







def 				A			(		__UpperCAmelCase							,					__UpperCAmelCase	)       ->       int:



						'''simple docstring'''






						return pointa[0] * pointa[1] - pointa[1] * pointa[0]







def 				A			(		__UpperCAmelCase							,					__UpperCAmelCase							,					__UpperCAmelCase							,					__UpperCAmelCase							,					__UpperCAmelCase							,					__UpperCAmelCase	)       ->       bool:



						'''simple docstring'''






						UpperCAmelCase_     							=     (xa, ya)
						UpperCAmelCase_     							=     (xa - xa, ya - ya)
						UpperCAmelCase_     							=     (xa - xa, ya - ya)
						UpperCAmelCase_     							=     -vector_product(__UpperCAmelCase							,					__UpperCAmelCase	) / vector_product(
						    __UpperCAmelCase							,					__UpperCAmelCase	)
						UpperCAmelCase_     							=     +vector_product(__UpperCAmelCase							,					__UpperCAmelCase	) / vector_product(
						    __UpperCAmelCase							,					__UpperCAmelCase	)

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







def 				A			(		__UpperCAmelCase = "p102_triangles.txt"	)       ->       int:



						'''simple docstring'''






						UpperCAmelCase_     							=     Path(__UpperCAmelCase	).parent.joinpath(__UpperCAmelCase	).read_text(encoding='''utf-8'''	)

						UpperCAmelCase_     							=     []
						for line in data.strip().split('''\n'''	):
												triangles.append([int(__UpperCAmelCase	) for number in line.split(''','''	)]	)

						UpperCAmelCase_     							=     0
						UpperCAmelCase_     							=     42

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

						return ret


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





