
from __future__ import annotations

import random





class 						lowercase       :
					__a					=    6
					def __init__(		self    ):
								"""simple docstring"""







								lowerCAmelCase__ :    Optional[int]				      =			list(range(1 ,	Dice.NUM_SIDES + 1    )    )
					def lowercase_			(		self    ):
								"""simple docstring"""







								return random.choice(self.sides    )





def      _a     (   __UpperCamelCase       :  int	,__UpperCamelCase       :  int = 2    ):
			lowerCAmelCase__ :    Tuple				      =			[Dice() for i in range(__UpperCamelCase    )]
			lowerCAmelCase__ :    int				      =			[0] * (len(__UpperCamelCase    ) * Dice.NUM_SIDES + 1)
			for _ in range(__UpperCamelCase    ):
						count_of_sum[sum(dice.roll() for dice in dices    )] += 1
			lowerCAmelCase__ :    Optional[Any]				      =			[round((count * 100) / num_throws	,2    ) for count in count_of_sum]
			return probability[num_dice:]  # remove probability of sums that never appear


if __name__ == "__main__":
							import doctest

							doctest.testmod()





import abc
import copy
import dataclasses
from dataclasses import dataclass
from typing import ClassVar, Dict, Type, TypeVar

from ..features import Features


A__       :   Tuple   						=					TypeVar("""T""", bound="""TaskTemplate""")





@dataclass(frozen=__UpperCamelCase					)
class 						lowercase       (  abc.ABC					):
					# `task` is not a ClassVar since we want it to be part of the `asdict` output for JSON serialization
					__a					=    42
					__a					=    42
					__a					=    42
					def lowercase_			(		self ,	SCREAMING_SNAKE_CASE__    ):
								"""simple docstring"""







								return copy.deepcopy(self    )
					@property
					def lowercase_			(		self    ):
								"""simple docstring"""







								return Features(**self.input_schema ,	**self.label_schema    )
					@property
					@abc.abstractmethod
					def lowercase_			(		self    ):
								"""simple docstring"""







								raise NotImplementedError
					@classmethod
					def lowercase_			(		cls ,	SCREAMING_SNAKE_CASE__    ):
								"""simple docstring"""







								lowerCAmelCase__ :    List[Any]				      =			{f.name for f in dataclasses.fields(cls    )}
								return cls(**{k: v for k, v in template_dict.items() if k in field_names}    )



