




"""simple docstring"""

def 					a			(    __snake_case  :					list,     __snake_case  :					list,     __snake_case  :					int	):



				'''simple docstring'''





				UpperCAmelCase_       :Dict         =   len(UpperCamelCase__	)
				UpperCAmelCase_       :Union[str, Any]         =   [[0] * n for i in range(UpperCamelCase__	)]
				for i in range(UpperCamelCase__	):
								UpperCAmelCase_       :List[Any]         =   y_points[i]

				for i in range(2,     UpperCamelCase__	):
								for j in range(UpperCamelCase__,     UpperCamelCase__	):
												UpperCAmelCase_       :Any         =   (
												    (xa - x_points[j - i + 1]) * q[j][i - 1]
												    - (xa - x_points[j]) * q[j - 1][i - 1]
												) / (x_points[j] - x_points[j - i + 1])

				return [q[n - 1][n - 1], q]


if __name__ == "__main__":
						import doctest

						doctest.testmod()









def 					SCREAMING_SNAKE_CASE__				(							UpperCamelCase__:				List[str]     ):
		SCREAMING_SNAKE_CASE__								=   len(UpperCamelCase__     )
		SCREAMING_SNAKE_CASE__								=   sum(UpperCamelCase__     )

		SCREAMING_SNAKE_CASE__								=   [[False for x in range(s + 1     )] for y in range(n + 1     )]

		for i in range(1       , n + 1     ):
				SCREAMING_SNAKE_CASE__								=   True

		for i in range(1       , s + 1     ):
				SCREAMING_SNAKE_CASE__								=   False

		for i in range(1       , n + 1     ):
				for j in range(1       , s + 1     ):
						SCREAMING_SNAKE_CASE__								=   dp[i][j - 1]

						if arr[i - 1] <= j:
								SCREAMING_SNAKE_CASE__								=   dp[i][j] or dp[i - 1][j - arr[i - 1]]

		for j in range(int(s / 2     )       , -1       , -1     ):
				if dp[n][j] is True:
						SCREAMING_SNAKE_CASE__								=   s - 2 * j
						break

		return diff