






"""simple docstring"""
import unittest
from timeit import timeit






def        lowerCamelCase_  (						_lowerCamelCase			,   _lowerCamelCase				):
 lowerCamelCase__     :			str     				=						first_num if first_num >= second_num else second_num
 lowerCamelCase__     :			Tuple     				=						max_num
 while (common_mult % first_num > 0) or (common_mult % second_num > 0):
  common_mult += max_num
 return common_mult






def        lowerCamelCase_  (						_lowerCamelCase			,   _lowerCamelCase				):
 return b if a == 0 else greatest_common_divisor(b % a			,   _lowerCamelCase				)






def        lowerCamelCase_  (						_lowerCamelCase			,   _lowerCamelCase				):
 return first_num // greatest_common_divisor(_lowerCamelCase			,   _lowerCamelCase				) * second_num






def        lowerCamelCase_  (						):
 lowerCamelCase__     :			Optional[Any]     				=						(
     'from __main__ import least_common_multiple_slow, least_common_multiple_fast'
 )
 print(
     'least_common_multiple_slow():'			,   timeit('least_common_multiple_slow(1000, 999)'			,   setup=_lowerCamelCase				)			,   )
 print(
     'least_common_multiple_fast():'			,   timeit('least_common_multiple_fast(1000, 999)'			,   setup=_lowerCamelCase				)			,   )



class 		a_      (	unittest.TestCase ):







      '''simple docstring'''

      lowerCamelCase__       :				List[Any] =	(
          (10, 20),
          (13, 15),
          (4, 31),
          (10, 42),
          (43, 34),
          (5, 12),
          (12, 25),
          (10, 25),
          (6, 9),
      )
      lowerCamelCase__       :				List[str] =	(20, 195, 124, 210, 1_462, 60, 300, 50, 18)




      def 			a__							(self					):

       '''simple docstring'''



       for i, (first_num, second_num) in enumerate(self.test_inputs					):
        lowerCamelCase__     :			str     				=						least_common_multiple_slow(lowerCamelCase_,     lowerCamelCase_					)
        lowerCamelCase__     :			Optional[int]     				=						least_common_multiple_fast(lowerCamelCase_,     lowerCamelCase_					)
        with self.subTest(i=lowerCamelCase_					):
         self.assertEqual(lowerCamelCase_,     self.expected_results[i]					)
         self.assertEqual(lowerCamelCase_,     self.expected_results[i]					)


if __name__ == "__main__":
      benchmark()
      unittest.main()









"""simple docstring"""


from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_tf_available,
    is_tokenizers_available,
    is_torch_available,
)


_UpperCamelCase				:    List[Any]     =						{
    'configuration_openai': ['OPENAI_GPT_PRETRAINED_CONFIG_ARCHIVE_MAP', 'OpenAIGPTConfig'],
    'tokenization_openai': ['OpenAIGPTTokenizer'],
}

try:
   if not is_tokenizers_available():
      raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
   pass
else:
   _UpperCamelCase				:    Any     =						['OpenAIGPTTokenizerFast']

try:
   if not is_torch_available():
      raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
   pass
else:
   _UpperCamelCase				:    int     =						[
       'OPENAI_GPT_PRETRAINED_MODEL_ARCHIVE_LIST',
       'OpenAIGPTDoubleHeadsModel',
       'OpenAIGPTForSequenceClassification',
       'OpenAIGPTLMHeadModel',
       'OpenAIGPTModel',
       'OpenAIGPTPreTrainedModel',
       'load_tf_weights_in_openai_gpt',
   ]

try:
   if not is_tf_available():
      raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
   pass
else:
   _UpperCamelCase				:    List[str]     =						[
       'TF_OPENAI_GPT_PRETRAINED_MODEL_ARCHIVE_LIST',
       'TFOpenAIGPTDoubleHeadsModel',
       'TFOpenAIGPTForSequenceClassification',
       'TFOpenAIGPTLMHeadModel',
       'TFOpenAIGPTMainLayer',
       'TFOpenAIGPTModel',
       'TFOpenAIGPTPreTrainedModel',
   ]


if TYPE_CHECKING:
   from .configuration_openai import OPENAI_GPT_PRETRAINED_CONFIG_ARCHIVE_MAP, OpenAIGPTConfig
   from .tokenization_openai import OpenAIGPTTokenizer

   try:
      if not is_tokenizers_available():
         raise OptionalDependencyNotAvailable()
   except OptionalDependencyNotAvailable:
      pass
   else:
      from .tokenization_openai_fast import OpenAIGPTTokenizerFast

   try:
      if not is_torch_available():
         raise OptionalDependencyNotAvailable()
   except OptionalDependencyNotAvailable:
      pass
   else:
      from .modeling_openai import (
          OPENAI_GPT_PRETRAINED_MODEL_ARCHIVE_LIST,
          OpenAIGPTDoubleHeadsModel,
          OpenAIGPTForSequenceClassification,
          OpenAIGPTLMHeadModel,
          OpenAIGPTModel,
          OpenAIGPTPreTrainedModel,
          load_tf_weights_in_openai_gpt,
      )

   try:
      if not is_tf_available():
         raise OptionalDependencyNotAvailable()
   except OptionalDependencyNotAvailable:
      pass
   else:
      from .modeling_tf_openai import (
          TF_OPENAI_GPT_PRETRAINED_MODEL_ARCHIVE_LIST,
          TFOpenAIGPTDoubleHeadsModel,
          TFOpenAIGPTForSequenceClassification,
          TFOpenAIGPTLMHeadModel,
          TFOpenAIGPTMainLayer,
          TFOpenAIGPTModel,
          TFOpenAIGPTPreTrainedModel,
      )

else:
   import sys

   _UpperCamelCase				:    Union[str, Any]     =						_LazyModule(__name__, globals()['__file__'], _import_structure, module_spec=__spec__)




