






'''simple docstring'''







from __future__ import annotations

import random
from collections.abc import Iterable
from typing import Any, Generic, TypeVar

a__  : Dict				=	TypeVar('T', bound=bool)
class  lowercase_					(   Generic[T]       ):


    def __init__(					self  , a   ):
          UpperCamelCase__  =    value
          UpperCamelCase__  =    None
          UpperCamelCase__  =    None


    @property
    def        __a							(					self   ):
          return self._value


    @staticmethod
    def        __a							(					a  , a   ):
          if not roota:
                return roota

          if not roota:
                return roota

          if roota.value > roota.value:
                UpperCamelCase__ ,     UpperCamelCase__  =    roota, roota

          if random.choice([True, False]   ):
                UpperCamelCase__ ,     UpperCamelCase__  =    roota.right, roota.left

          UpperCamelCase__  =    RandomizedHeapNode.merge(roota.left  , a   )

          return roota

class  lowercase_					(   Generic[T]       ):


    def __init__(					self  , a = ()   ):
          UpperCamelCase__  =    None

          if data:
                for item in data:
                      self.insert(a   )


    def        __a							(					self  , a   ):
          UpperCamelCase__  =    RandomizedHeapNode.merge(self._root  , RandomizedHeapNode(a   )   )


    def        __a							(					self   ):
          UpperCamelCase__  =    self.top()

          if self._root is None:
                return None

          UpperCamelCase__  =    RandomizedHeapNode.merge(self._root.left  , self._root.right   )

          return result


    def        __a							(					self   ):
          if not self._root:
                raise IndexError("Can't get top element for the empty heap."   )
          return self._root.value


    def        __a							(					self   ):
          UpperCamelCase__  =    None


    def        __a							(					self   ):
          UpperCamelCase__  =    []
          while self:
                result.append(self.pop()   )

          return result


    def __bool__(					self   ):
          return self._root is not None


if __name__ == "__main__":
  import doctest

  doctest.testmod()









'''simple docstring'''







import math







def _UpperCamelCase	(					__A   )							->		bool:


      '''simple docstring'''



      if 1 < number < 4:
            # 2 and 3 are primes
            return True
      elif number < 2 or number % 2 == 0 or number % 3 == 0:
            # Negatives, 0, 1, all even numbers, all multiples of 3 are not primes
            return False

      # All primes number are in format of 6k +/- 1
      for i in range(5				,      int(math.sqrt(__A   ) + 1   )				,      6   ):
            if number % i == 0 or number % (i + 2) == 0:
                  return False
      return True







def _UpperCamelCase	(					__A = 1000				,      __A = 1000   )							->		int:


      '''simple docstring'''



      UpperCamelCase__  =    [0, 0, 0]  # length, a, b
      for a in range((a_limit * -1) + 1				,      __A   ):
            for b in range(2				,      __A   ):
                  if is_prime(__A   ):
                        UpperCamelCase__  =    0
                        UpperCamelCase__  =    0
                        while is_prime((n**2) + (a * n) + b   ):
                              count += 1
                              n += 1
                        if count > longest[0]:
                              UpperCamelCase__  =    [count, a, b]
      UpperCamelCase__  =    longest[1] * longest[2]
      return ans


if __name__ == "__main__":
  print(solution(1_0_0_0, 1_0_0_0))





