






import os






def 						a    (		):






				'''simple docstring'''
				lowercase__     				=    os.path.dirname(os.path.realpath(lowerCamelCase_       )       )
				lowercase__     				=    os.path.join(lowerCamelCase_	,     '''triangle.txt'''       )

				with open(lowerCamelCase_       ) as f:
								lowercase__     				=    f.readlines()

				lowercase__     				=    []
				for line in triangle:
								lowercase__     				=    []
								for number in line.strip().split(''' '''       ):
												numbers_from_line.append(int(lowerCamelCase_       )       )
								a.append(lowerCamelCase_       )

				for i in range(1	,     len(lowerCamelCase_       )       ):
								for j in range(len(a[i]       )       ):
												lowercase__     				=    a[i - 1][j] if j != len(a[i - 1]       ) else 0
												lowercase__     				=    a[i - 1][j - 1] if j > 0 else 0
												a[i][j] += max(lowerCamelCase_	,     lowerCamelCase_       )
				return max(a[-1]       )


if __name__ == "__main__":
							print(solution())












from transformers import DistilBertTokenizer, DistilBertTokenizerFast
from transformers.testing_utils import require_tokenizers, slow

from ..bert.test_tokenization_bert import BertTokenizationTest
@require_tokenizers
class    _UpperCAmelCase      ( A__			):

				"""simple docstring"""




				lowercase__       							= DistilBertTokenizer
				lowercase__       							= DistilBertTokenizerFast
				lowercase__       							= True




				@slow
				def        lowercase__     (  self		:					str						):

								'''simple docstring'''
								lowercase__     				=    DistilBertTokenizer.from_pretrained('''distilbert-base-uncased'''						)

								lowercase__     				=    tokenizer.encode('''sequence builders''',						add_special_tokens=lowerCamelCase						)
								lowercase__     				=    tokenizer.encode('''multi-sequence build''',						add_special_tokens=lowerCamelCase						)

								lowercase__     				=    tokenizer.build_inputs_with_special_tokens(lowerCamelCase						)
								lowercase__     				=    tokenizer.build_inputs_with_special_tokens(lowerCamelCase,						lowerCamelCase						)

								assert encoded_sentence == [tokenizer.cls_token_id] + text + [tokenizer.sep_token_id]
								assert encoded_pair == [tokenizer.cls_token_id] + text + [tokenizer.sep_token_id] + text_a + [
								    tokenizer.sep_token_id
								]




