


class   __a			:
 def __init__(   self				, lowerCAmelCase__ )					->				Dict:




        '''simple docstring'''
        # we need a list not a string, so do something to change the type
        lowercase__:   List[str]  			=   arr.split(',' )
 def 		SCREAMING_SNAKE_CASE__   (   self )					->				Optional[int]:




        '''simple docstring'''
        lowercase__:   Tuple  			=   [int(self.array[0] )] * len(self.array )
        lowercase__:   Optional[Any]  			=   [int(self.array[0] )] * len(self.array )
        for i in range(1				, len(self.array ) ):
               lowercase__:   Optional[Any]  			=   max(
                   int(self.array[i] ) + sum_value[i - 1]				, int(self.array[i] ) )
               lowercase__:   Union[str, Any]  			=   max(sum_value[i]				, rear[i - 1] )
        return rear[len(self.array ) - 1]


if __name__ == "__main__":
 __lowerCAmelCase		       =							input('''please input some numbers:''')
 __lowerCAmelCase		       =							SubArray(whole_array)
 __lowerCAmelCase		       =							array.solve_sub_array()
 print(('''the results is:''', re))






import os
import unittest

from transformers.models.cpmant.tokenization_cpmant import VOCAB_FILES_NAMES, CpmAntTokenizer
from transformers.testing_utils import require_jieba, tooslow

from ...test_tokenization_common import TokenizerTesterMixin





@require_jieba
class   __a			(    __UpperCamelCase       ,       unittest.TestCase      ):
 __lowercase :							str        = CpmAntTokenizer
 __lowercase :							List[Any]        = False
 def 		SCREAMING_SNAKE_CASE__   (   self )					->				str:




        '''simple docstring'''
        super().setUp()

        lowercase__:   Any  			=   [
            '<d>',
            '</d>',
            '<s>',
            '</s>',
            '</_>',
            '<unk>',
            '<pad>',
            '</n>',
            '我',
            '是',
            'C',
            'P',
            'M',
            'A',
            'n',
            't',
        ]
        lowercase__:   List[Any]  			=   os.path.join(self.tmpdirname				, VOCAB_FILES_NAMES['vocab_file'] )
        with open(self.vocab_file				, 'w'				, encoding='utf-8' ) as vocab_writer:
               vocab_writer.write(''.join([x + '\n' for x in vocab_tokens] ) )
 @tooslow
 def 		SCREAMING_SNAKE_CASE__   (   self )					->				Tuple:




        '''simple docstring'''
        lowercase__:   Optional[int]  			=   CpmAntTokenizer.from_pretrained('openbmb/cpm-ant-10b' )
        lowercase__:   Optional[Any]  			=   '今天天气真好！'
        lowercase__:   str  			=   ['今天', '天气', '真', '好', '！']
        lowercase__:   Optional[Any]  			=   tokenizer.tokenize(lowerCAmelCase__ )
        self.assertListEqual(lowerCAmelCase__				, lowerCAmelCase__ )
        lowercase__:   List[str]  			=   '今天天气真好！'
        lowercase__:   List[str]  			=   [tokenizer.bos_token] + tokens

        lowercase__:   Tuple  			=   [6, 9_802, 14_962, 2_082, 831, 244]
        self.assertListEqual(tokenizer.convert_tokens_to_ids(lowerCAmelCase__ )				, lowerCAmelCase__ )

        lowercase__:   Any  			=   tokenizer.decode(lowerCAmelCase__ )
        self.assertEqual(lowerCAmelCase__				, lowerCAmelCase__ )


