





from ..utils import DummyObject, requires_backends



class    A__  (			metaclass=_lowerCamelCase     ):
      _UpperCAmelCase      :List[Any]		       =  ['note_seq']





      def __init__(					self			,				*A_			,				**A_  ):
       '''simple docstring'''




       requires_backends(self			,				["note_seq"]  )





      @classmethod
      def 			__UpperCamelCase(					cls			,				*A_			,				**A_  ):
       '''simple docstring'''




       requires_backends(cls			,				["note_seq"]  )





      @classmethod
      def 			__UpperCamelCase(					cls			,				*A_			,				**A_  ):
       '''simple docstring'''




       requires_backends(cls			,				["note_seq"]  )





from collections.abc import Sequence






def  lowerCamelCase_	(      lowerCAmelCase__	:	Sequence[int] | None = None				)       ->							int:

							'''simple docstring'''






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

							A      						=    nums[0]
							for i in range(1			,	len(lowerCAmelCase__				)				):
														A      						=    nums[i]
														A      						=    max(lowerCAmelCase__			,	ans + num			,	lowerCAmelCase__				)

							return ans


if __name__ == "__main__":
				import doctest

				doctest.testmod()

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