




from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_tf_available, is_torch_available


UpperCamelCase__ :   Union[str, Any]						=							{
    '''configuration_xlm''': ['''XLM_PRETRAINED_CONFIG_ARCHIVE_MAP''', '''XLMConfig''', '''XLMOnnxConfig'''],
    '''tokenization_xlm''': ['''XLMTokenizer'''],
}

try:
						if not is_torch_available():
												raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
						pass
else:
						UpperCamelCase__ :   Tuple						=							[
						    '''XLM_PRETRAINED_MODEL_ARCHIVE_LIST''',
						    '''XLMForMultipleChoice''',
						    '''XLMForQuestionAnswering''',
						    '''XLMForQuestionAnsweringSimple''',
						    '''XLMForSequenceClassification''',
						    '''XLMForTokenClassification''',
						    '''XLMModel''',
						    '''XLMPreTrainedModel''',
						    '''XLMWithLMHeadModel''',
						]

try:
						if not is_tf_available():
												raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
						pass
else:
						UpperCamelCase__ :   Any						=							[
						    '''TF_XLM_PRETRAINED_MODEL_ARCHIVE_LIST''',
						    '''TFXLMForMultipleChoice''',
						    '''TFXLMForQuestionAnsweringSimple''',
						    '''TFXLMForSequenceClassification''',
						    '''TFXLMForTokenClassification''',
						    '''TFXLMMainLayer''',
						    '''TFXLMModel''',
						    '''TFXLMPreTrainedModel''',
						    '''TFXLMWithLMHeadModel''',
						]


if TYPE_CHECKING:
						from .configuration_xlm import XLM_PRETRAINED_CONFIG_ARCHIVE_MAP, XLMConfig, XLMOnnxConfig
						from .tokenization_xlm import XLMTokenizer

						try:
												if not is_torch_available():
																		raise OptionalDependencyNotAvailable()
						except OptionalDependencyNotAvailable:
												pass
						else:
												from .modeling_xlm import (
												    XLM_PRETRAINED_MODEL_ARCHIVE_LIST,
												    XLMForMultipleChoice,
												    XLMForQuestionAnswering,
												    XLMForQuestionAnsweringSimple,
												    XLMForSequenceClassification,
												    XLMForTokenClassification,
												    XLMModel,
												    XLMPreTrainedModel,
												    XLMWithLMHeadModel,
												)

						try:
												if not is_tf_available():
																		raise OptionalDependencyNotAvailable()
						except OptionalDependencyNotAvailable:
												pass
						else:
												from .modeling_tf_xlm import (
												    TF_XLM_PRETRAINED_MODEL_ARCHIVE_LIST,
												    TFXLMForMultipleChoice,
												    TFXLMForQuestionAnsweringSimple,
												    TFXLMForSequenceClassification,
												    TFXLMForTokenClassification,
												    TFXLMMainLayer,
												    TFXLMModel,
												    TFXLMPreTrainedModel,
												    TFXLMWithLMHeadModel,
												)

else:
						import sys

						UpperCamelCase__ :   List[str]						=							_LazyModule(__name__, globals()['''__file__'''], _import_structure, module_spec=__spec__)







"""simple docstring"""


from decimal import Decimal, getcontext
from math import ceil, factorial


def    _lowerCamelCase   (     lowerCamelCase__	:							int  ):

 if not isinstance(lowerCamelCase__       ,		lowerCamelCase__  ):
  raise TypeError("""Undefined for non-integers"""  )
 elif precision < 1:
  raise ValueError("""Undefined for non-natural numbers"""  )

 lowercase__       :       List[str]				=						precision
 lowercase__       :       Optional[int]				=						ceil(precision / 14  )
 lowercase__       :       Union[str, Any]				=						42_68_80 * Decimal(1_00_05  ).sqrt()
 lowercase__       :       Optional[Any]				=						1
 lowercase__       :       Optional[Any]				=						13_59_14_09
 lowercase__       :       List[Any]				=						Decimal(lowerCamelCase__  )
 for k in range(1       ,		lowerCamelCase__  ):
  lowercase__       :       Optional[int]				=						factorial(6 * k  ) // (factorial(3 * k  ) * factorial(lowerCamelCase__  ) ** 3)
  linear_term += 5_45_14_01_34
  exponential_term *= -26_25_37_41_26_40_76_80_00
  partial_sum += Decimal(multinomial_term * linear_term  ) / exponential_term
 return str(constant_term / partial_sum  )[:-1]


if __name__ == "__main__":
   __snake_case    					=					50
   print(F"The first {n} digits of pi is: {pi(n)}")