

'''simple docstring'''



from __future__ import annotations


def       snake_case   (	snake_case      : list[int]			) ->  int:


    """simple docstring"""


    if not nums:
        return 0
    lowerCAmelCase 						=							nums[0]
    lowerCAmelCase 						=							0
    for num in nums[1:]:
        lowerCAmelCase						,   lowerCAmelCase 						=							(
            max_excluding + num,
            max(snake_case					,		snake_case			),
        )
    return max(snake_case					,		snake_case			)


if __name__ == "__main__":
     import doctest

     doctest.testmod()








'''simple docstring'''



def       snake_case   (	snake_case      : int					,		snake_case      : int					,		snake_case      : int			) ->  int:


    """simple docstring"""


    if exponent == 1:
        return base
    if exponent % 2 == 0:
        lowerCAmelCase 						=							_modexpt(snake_case					,		exponent // 2					,		snake_case			) % modulo_value
        return (x * x) % modulo_value
    else:
        return (base * _modexpt(snake_case					,		exponent - 1					,		snake_case			)) % modulo_value


def       snake_case   (	snake_case      : int = 1777					,		snake_case      : int = 1855					,		snake_case      : int = 8			) ->  int:


    """simple docstring"""


    lowerCAmelCase 						=							base
    for _ in range(1					,		snake_case			):
        lowerCAmelCase 						=							_modexpt(snake_case					,		snake_case					,		10**digits			)

    return result


if __name__ == "__main__":
     print(F"""{solution() = }""")





