





def 					_A	(		SCREAMING_SNAKE_CASE					:       List[str]						):





  """simple docstring"""



  a__     : Tuple  =[]
  a__     : Dict  =set({"(", "[", "{"}						)
  a__     : Dict  =set({")", "]", "}"}						)
  a__     : List[str]  ={"{": "}", "[": "]", "(": ")"}

  for i in range(len(SCREAMING_SNAKE_CASE						)						):
    if s[i] in open_brackets:
      stack.append(s[i]						)

    elif s[i] in closed_brackets and (
        len(SCREAMING_SNAKE_CASE						) == 0 or (len(SCREAMING_SNAKE_CASE						) > 0 and open_to_closed[stack.pop()] != s[i])
    ):
      return False

  return len(SCREAMING_SNAKE_CASE						) == 0
def 					_A	(		):





  """simple docstring"""



  a__     : List[str]  =input("Enter sequence of brackets: "						)
  if is_balanced(SCREAMING_SNAKE_CASE						):
    print(SCREAMING_SNAKE_CASE	,	"is balanced"						)
  else:
    print(SCREAMING_SNAKE_CASE	,	"is not balanced"						)


if __name__ == "__main__":
     main()













from maths.prime_check import is_prime
def 					_A	(		SCREAMING_SNAKE_CASE					:       int						):





  """simple docstring"""



  if not isinstance(SCREAMING_SNAKE_CASE	,	SCREAMING_SNAKE_CASE						):
    a__     : Dict  =f'''Input value of [number={number}] must be an integer'''
    raise TypeError(SCREAMING_SNAKE_CASE						)
  if is_prime(SCREAMING_SNAKE_CASE						) and is_prime(number + 2						):
    return number + 2
  else:
    return -1


if __name__ == "__main__":
     import doctest

     doctest.testmod()






