



def        a__     (				lowerCAmelCase__     ,      lowerCAmelCase__				):



      if not (isinstance(A__     ,      A__				) and isinstance(A__     ,      A__				)):
            raise ValueError("longest_common_substring() takes two strings for inputs"				)

      UpperCAmelCase_      			=							len(A__				)
      UpperCAmelCase_      			=							len(A__				)

      UpperCAmelCase_      			=							[[0] * (texta_length + 1) for _ in range(texta_length + 1				)]
      UpperCAmelCase_      			=							0
      UpperCAmelCase_      			=							0

      for i in range(1     ,      texta_length + 1				):
            for j in range(1     ,      texta_length + 1				):
                  if texta[i - 1] == texta[j - 1]:
                        UpperCAmelCase_      			=							1 + dp[i - 1][j - 1]
                        if dp[i][j] > ans_length:
                              UpperCAmelCase_      			=							i
                              UpperCAmelCase_      			=							dp[i][j]

      return texta[ans_index - ans_length : ans_index]


if __name__ == "__main__":
  import doctest

  doctest.testmod()









"""simple docstring"""





from ..utils import DummyObject, requires_backends
class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  Tuple		,    *_UpperCAmelCase      :  str		,    **_UpperCAmelCase      :  Any   )			->						List[str]:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  List[Any]		,    *_UpperCAmelCase      :  Dict		,    **_UpperCAmelCase      :  Tuple   )			->						List[Any]:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  List[Any]		,    *_UpperCAmelCase      :  List[Any]		,    **_UpperCAmelCase      :  str   )			->						int:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  Union[str, Any]		,    *_UpperCAmelCase      :  Any		,    **_UpperCAmelCase      :  Tuple   )			->						str:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  str		,    *_UpperCAmelCase      :  Optional[int]		,    **_UpperCAmelCase      :  int   )			->						Any:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  List[str]		,    *_UpperCAmelCase      :  Optional[Any]		,    **_UpperCAmelCase      :  Optional[int]   )			->						Dict:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  Union[str, Any]		,    *_UpperCAmelCase      :  Dict		,    **_UpperCAmelCase      :  Dict   )			->						str:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  Optional[int]		,    *_UpperCAmelCase      :  int		,    **_UpperCAmelCase      :  List[Any]   )			->						List[str]:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  Dict		,    *_UpperCAmelCase      :  Dict		,    **_UpperCAmelCase      :  Union[str, Any]   )			->						int:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  Any		,    *_UpperCAmelCase      :  str		,    **_UpperCAmelCase      :  Tuple   )			->						Optional[int]:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  str		,    *_UpperCAmelCase      :  Optional[Any]		,    **_UpperCAmelCase      :  List[str]   )			->						str:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  int		,    *_UpperCAmelCase      :  Any		,    **_UpperCAmelCase      :  int   )			->						Dict:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  str		,    *_UpperCAmelCase      :  int		,    **_UpperCAmelCase      :  Dict   )			->						Tuple:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  Optional[Any]		,    *_UpperCAmelCase      :  List[str]		,    **_UpperCAmelCase      :  List[Any]   )			->						List[Any]:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  List[Any]		,    *_UpperCAmelCase      :  int		,    **_UpperCAmelCase      :  int   )			->						Optional[Any]:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  Dict		,    *_UpperCAmelCase      :  Any		,    **_UpperCAmelCase      :  Optional[Any]   )			->						int:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  List[Any]		,    *_UpperCAmelCase      :  str		,    **_UpperCAmelCase      :  List[str]   )			->						Any:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  List[str]		,    *_UpperCAmelCase      :  str		,    **_UpperCAmelCase      :  Optional[Any]   )			->						Tuple:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  Union[str, Any]		,    *_UpperCAmelCase      :  Optional[int]		,    **_UpperCAmelCase      :  Tuple   )			->						str:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  str		,    *_UpperCAmelCase      :  Union[str, Any]		,    **_UpperCAmelCase      :  Union[str, Any]   )			->						List[str]:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  List[Any]		,    *_UpperCAmelCase      :  Optional[int]		,    **_UpperCAmelCase      :  Optional[Any]   )			->						str:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  Optional[Any]		,    *_UpperCAmelCase      :  str		,    **_UpperCAmelCase      :  int   )			->						Union[str, Any]:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  Union[str, Any]		,    *_UpperCAmelCase      :  Optional[Any]		,    **_UpperCAmelCase      :  List[Any]   )			->						str:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  List[Any]		,    *_UpperCAmelCase      :  Dict		,    **_UpperCAmelCase      :  str   )			->						List[str]:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  List[str]		,    *_UpperCAmelCase      :  Optional[int]		,    **_UpperCAmelCase      :  Optional[int]   )			->						Tuple:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  Union[str, Any]		,    *_UpperCAmelCase      :  Optional[int]		,    **_UpperCAmelCase      :  str   )			->						Union[str, Any]:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  Optional[int]		,    *_UpperCAmelCase      :  Any		,    **_UpperCAmelCase      :  List[str]   )			->						Optional[int]:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  Optional[Any]		,    *_UpperCAmelCase      :  Union[str, Any]		,    **_UpperCAmelCase      :  Optional[Any]   )			->						Tuple:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  Optional[int]		,    *_UpperCAmelCase      :  Union[str, Any]		,    **_UpperCAmelCase      :  Dict   )			->						Any:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  List[str]		,    *_UpperCAmelCase      :  List[str]		,    **_UpperCAmelCase      :  Optional[Any]   )			->						List[str]:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  Tuple		,    *_UpperCAmelCase      :  List[str]		,    **_UpperCAmelCase      :  Optional[int]   )			->						Tuple:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  Any		,    *_UpperCAmelCase      :  Tuple		,    **_UpperCAmelCase      :  Optional[int]   )			->						Any:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  List[Any]		,    *_UpperCAmelCase      :  int		,    **_UpperCAmelCase      :  int   )			->						int:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  Tuple		,    *_UpperCAmelCase      :  int		,    **_UpperCAmelCase      :  Any   )			->						List[Any]:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  str		,    *_UpperCAmelCase      :  int		,    **_UpperCAmelCase      :  str   )			->						Any:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  int		,    *_UpperCAmelCase      :  Dict		,    **_UpperCAmelCase      :  List[Any]   )			->						Dict:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )



class 				lowercase__       (   metaclass=SCREAMING_SNAKE_CASE				):







       '''simple docstring'''


       UpperCamelCase						=					['''flax''']



       def __init__(							self      :  int		,    *_UpperCAmelCase      :  Any		,    **_UpperCAmelCase      :  int   )			->						Union[str, Any]:


             '''simple docstring'''




             requires_backends(self		,    ["flax"]   )



       @classmethod
       def 					lowercase__    (							cls      :  Optional[int]		,    *_UpperCAmelCase      :  Dict		,    **_UpperCAmelCase      :  Dict   )			->						Dict:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )







       @classmethod
       def 					lowercase__    (							cls      :  str		,    *_UpperCAmelCase      :  Dict		,    **_UpperCAmelCase      :  Any   )			->						List[str]:


             '''simple docstring'''




             requires_backends(cls		,    ["flax"]   )




