






from itertools import product


def 				snake_case__							(							UpperCAmelCase							:  int    ,			UpperCAmelCase							:  int       ):
    lowerCAmelCase__   :List[str]      							=				sides_number
    lowerCAmelCase__   :Dict      							=				max_face_number * dice_number
    lowerCAmelCase__   :Optional[int]      							=				[0] * (max_total + 1)

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

    return totals_frequencies


def 				snake_case__							(							):
    lowerCAmelCase__   :List[Any]      							=				total_frequency_distribution(
        sides_number=4    ,			dice_number=9       )
    lowerCAmelCase__   :int      							=				total_frequency_distribution(
        sides_number=6    ,			dice_number=6       )

    lowerCAmelCase__   :str      							=				0
    lowerCAmelCase__   :Dict      							=				9
    lowerCAmelCase__   :Optional[Any]      							=				4 * 9
    lowerCAmelCase__   :int      							=				6
    for peter_total in range(UpperCAmelCase    ,			max_peter_total + 1       ):
        peter_wins_count += peter_totals_frequencies[peter_total] * sum(
            colin_totals_frequencies[min_colin_total:peter_total]       )

    lowerCAmelCase__   :str      							=				(4**9) * (6**6)
    lowerCAmelCase__   :Any      							=				peter_wins_count / total_games_number

    lowerCAmelCase__   :List[str]      							=				round(UpperCAmelCase    ,			ndigits=7       )

    return rounded_peter_win_probability


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











from __future__ import annotations

import math
from collections.abc import Callable


def 				snake_case__							(							UpperCAmelCase							:  Callable[[int | float], int | float]    ,			UpperCAmelCase							:  int | float    ,			UpperCAmelCase							:  int | float    ,			UpperCAmelCase							:  int = 1_0_0    ,			):
    lowerCAmelCase__   :int      							=				x_start
    lowerCAmelCase__   :int      							=				fnc(UpperCAmelCase       )
    lowerCAmelCase__   :List[Any]      							=				0.0

    for _ in range(UpperCAmelCase       ):
        # Approximates curve as a sequence of linear lines and sums their length
        lowerCAmelCase__   :Dict      							=				(x_end - x_start) / steps + xa
        lowerCAmelCase__   :Optional[Any]      							=				fnc(UpperCAmelCase       )
        length += math.hypot(xa - xa    ,			fxa - fxa       )

        # Increment step
        lowerCAmelCase__   :Union[str, Any]      							=				xa
        lowerCAmelCase__   :str      							=				fxa

    return length


if __name__ == "__main__":


 def 				snake_case__							(							UpperCAmelCase							:  int       ):
     return math.sin(1_0 * x       )

 print("""f(x) = sin(10 * x)""")
 print("""The length of the curve from x = -10 to x = 10 is:""")
 _a    :   Any        =			10
 while i <= 10_0000:
  print(f"""With {i} steps: {line_length(f, -10, 10, i)}""")
  i *= 10



