



"""simple docstring"""







from itertools import product



def 	__UpperCAmelCase (       __lowerCamelCase		,	__lowerCamelCase      )				-> Union[str, Any]:
		lowercase__  :       Dict												=     sides_number
		lowercase__  :       List[str]												=     max_face_number * dice_number
		lowercase__  :       Dict												=     [0] * (max_total + 1)

		lowercase__  :       Any												=     1
		lowercase__  :       str												=     range(__lowerCamelCase		,	max_face_number + 1      )
		for dice_numbers in product(__lowerCamelCase		,	repeat=__lowerCamelCase      ):
				lowercase__  :       Optional[int]												=     sum(__lowerCamelCase      )
				totals_frequencies[total] += 1

		return totals_frequencies



def 	__UpperCAmelCase (       )				-> Union[str, Any]:
		lowercase__  :       int												=     total_frequency_distribution(
		    sides_number=4		,	dice_number=9      )
		lowercase__  :       List[Any]												=     total_frequency_distribution(
		    sides_number=6		,	dice_number=6      )

		lowercase__  :       int												=     0
		lowercase__  :       str												=     9
		lowercase__  :       List[Any]												=     4 * 9
		lowercase__  :       Union[str, Any]												=     6
		for peter_total in range(__lowerCamelCase		,	max_peter_total + 1      ):
				peter_wins_count += peter_totals_frequencies[peter_total] * sum(
				    colin_totals_frequencies[min_colin_total:peter_total]      )

		lowercase__  :       Union[str, Any]												=     (4**9) * (6**6)
		lowercase__  :       int												=     peter_wins_count / total_games_number

		lowercase__  :       str												=     round(__lowerCamelCase		,	ndigits=7      )

		return rounded_peter_win_probability


if __name__ == "__main__":
							print(F'''{solution() = }''')




'''simple docstring'''


from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_flax_available,
    is_tf_available,
    is_torch_available,
    is_vision_available,
)


_UpperCamelCase 							=  {"""configuration_vit""": ["""VIT_PRETRAINED_CONFIG_ARCHIVE_MAP""", """ViTConfig""", """ViTOnnxConfig"""]}

try:
      if not is_vision_available():
            raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
      pass
else:
      _UpperCamelCase 							=  ["""ViTFeatureExtractor"""]
      _UpperCamelCase 							=  ["""ViTImageProcessor"""]

try:
      if not is_torch_available():
            raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
      pass
else:
      _UpperCamelCase 							=  [
          """VIT_PRETRAINED_MODEL_ARCHIVE_LIST""",
          """ViTForImageClassification""",
          """ViTForMaskedImageModeling""",
          """ViTModel""",
          """ViTPreTrainedModel""",
      ]

try:
      if not is_tf_available():
            raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
      pass
else:
      _UpperCamelCase 							=  [
          """TFViTForImageClassification""",
          """TFViTModel""",
          """TFViTPreTrainedModel""",
      ]

try:
      if not is_flax_available():
            raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
      pass
else:
      _UpperCamelCase 							=  [
          """FlaxViTForImageClassification""",
          """FlaxViTModel""",
          """FlaxViTPreTrainedModel""",
      ]

if TYPE_CHECKING:
      from .configuration_vit import VIT_PRETRAINED_CONFIG_ARCHIVE_MAP, ViTConfig, ViTOnnxConfig

      try:
            if not is_vision_available():
                  raise OptionalDependencyNotAvailable()
      except OptionalDependencyNotAvailable:
            pass
      else:
            from .feature_extraction_vit import ViTFeatureExtractor
            from .image_processing_vit import ViTImageProcessor

      try:
            if not is_torch_available():
                  raise OptionalDependencyNotAvailable()
      except OptionalDependencyNotAvailable:
            pass
      else:
            from .modeling_vit import (
                VIT_PRETRAINED_MODEL_ARCHIVE_LIST,
                ViTForImageClassification,
                ViTForMaskedImageModeling,
                ViTModel,
                ViTPreTrainedModel,
            )

      try:
            if not is_tf_available():
                  raise OptionalDependencyNotAvailable()
      except OptionalDependencyNotAvailable:
            pass
      else:
            from .modeling_tf_vit import TFViTForImageClassification, TFViTModel, TFViTPreTrainedModel

      try:
            if not is_flax_available():
                  raise OptionalDependencyNotAvailable()
      except OptionalDependencyNotAvailable:
            pass
      else:
            from .modeling_flax_vit import FlaxViTForImageClassification, FlaxViTModel, FlaxViTPreTrainedModel


else:
      import sys

      _UpperCamelCase 							=  _LazyModule(__name__, globals()["""__file__"""], _import_structure, module_spec=__spec__)

