
lowerCamelCase__    :		Union[str, Any]          =   """Alexander Joslin"""

import operator as op

from .stack import Stack

def 		UpperCamelCase	(      lowercase_   )		->	int:


  '''simple docstring'''






  lowercase__  :   Optional[int]    		=      {"""*""": op.mul, """/""": op.truediv, """+""": op.add, """-""": op.sub}

  lowercase__  :   Stack[int]    		=      Stack()
  lowercase__  :   Stack[str]    		=      Stack()

  for i in equation:
    if i.isdigit():
      # RULE 1
      operand_stack.push(int(lowercase_   )   )
    elif i in operators:
      # RULE 2
      operator_stack.push(lowercase_   )
    elif i == ")":
      # RULE 4
      lowercase__  :   int    		=      operator_stack.peek()
      operator_stack.pop()
      lowercase__  :   Optional[int]    		=      operand_stack.peek()
      operand_stack.pop()
      lowercase__  :   Union[str, Any]    		=      operand_stack.peek()
      operand_stack.pop()

      lowercase__  :   Optional[int]    		=      operators[opr](lowercase_ , lowercase_   )
      operand_stack.push(lowercase_   )

    # RULE 5
  return operand_stack.peek()


if __name__ == "__main__":
     lowerCamelCase__    :		List[str]          =   """(5 + ((4 * 2) * (2 + 3)))"""
     # answer = 45
     print(f'''{equation} = {dijkstras_two_stack_algorithm(equation)}''')








def 		UpperCamelCase	(      lowercase_ = 10_00   )		->	int:


  '''simple docstring'''






  return sum(2 * a * ((a - 1) // 2) for a in range(3 , n + 1   )   )


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






