'''simple docstring'''





from collections.abc import Sequence
def 						__A							(     UpperCAmelCase = None					)     ->			Optional[Any]:




						'''simple docstring'''


						if nums is None or not nums:
												raise ValueError("Input sequence should not be empty"					)

						_UpperCamelCase			:			str   			=						nums[0]
						for i in range(1     ,len(_UpperCamelCase					)					):
												_UpperCamelCase			:			Dict   			=						nums[i]
												_UpperCamelCase			:			Dict   			=						max(_UpperCamelCase     ,ans + num     ,_UpperCamelCase					)

						return ans


if __name__ == "__main__":
			import doctest

			doctest.testmod()

			# Try on a sample input from the user
			lowerCAmelCase_	:		str			=     int(input("""Enter number of elements : """).strip())
			lowerCAmelCase_	:		int			=     list(map(int, input("""\nEnter the numbers : """).strip().split()))[:n]
			print(max_subsequence_sum(array))







'''simple docstring'''





from __future__ import annotations

from cmath import sqrt
def 						__A							(     UpperCAmelCase     ,UpperCAmelCase     ,UpperCAmelCase					)     ->			tuple[complex, complex]:




						'''simple docstring'''

						if a == 0:
												raise ValueError("Coefficient 'a' must not be zero."					)
						_UpperCamelCase			:			List[str]   			=						b * b - 4 * a * c

						_UpperCamelCase			:			Dict   			=						(-b + sqrt(UpperCAmelCase					)) / (2 * a)
						_UpperCamelCase			:			Optional[int]   			=						(-b - sqrt(UpperCAmelCase					)) / (2 * a)

						return (
						    root_a.real if not root_a.imag else root_a,
						    root_a.real if not root_a.imag else root_a,
						)
def 						__A							(     )     ->			List[Any]:




						'''simple docstring'''
						_UpperCamelCase			,       _UpperCamelCase			:			Any   			=						quadratic_roots(a=5     ,b=6     ,c=1					)
						print(f'''The solutions are: {solutiona} and {solutiona}'''					)


if __name__ == "__main__":
			main()


