




from typing import TYPE_CHECKING

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


lowercase__							:							Optional[int]													=     {"configuration_cvt": ["CVT_PRETRAINED_CONFIG_ARCHIVE_MAP", "CvtConfig"]}


try:
				if not is_torch_available():
								raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
				pass
else:
				lowercase__							:							str													=     [
				    "CVT_PRETRAINED_MODEL_ARCHIVE_LIST",
				    "CvtForImageClassification",
				    "CvtModel",
				    "CvtPreTrainedModel",
				]

try:
				if not is_tf_available():
								raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
				pass
else:
				lowercase__							:							str													=     [
				    "TF_CVT_PRETRAINED_MODEL_ARCHIVE_LIST",
				    "TFCvtForImageClassification",
				    "TFCvtModel",
				    "TFCvtPreTrainedModel",
				]

if TYPE_CHECKING:
				from .configuration_cvt import CVT_PRETRAINED_CONFIG_ARCHIVE_MAP, CvtConfig

				try:
								if not is_torch_available():
												raise OptionalDependencyNotAvailable()
				except OptionalDependencyNotAvailable:
								pass
				else:
								from .modeling_cvt import (
								    CVT_PRETRAINED_MODEL_ARCHIVE_LIST,
								    CvtForImageClassification,
								    CvtModel,
								    CvtPreTrainedModel,
								)

				try:
								if not is_tf_available():
												raise OptionalDependencyNotAvailable()
				except OptionalDependencyNotAvailable:
								pass
				else:
								from .modeling_tf_cvt import (
								    TF_CVT_PRETRAINED_MODEL_ARCHIVE_LIST,
								    TFCvtForImageClassification,
								    TFCvtModel,
								    TFCvtPreTrainedModel,
								)


else:
				import sys

				lowercase__							:							int													=     _LazyModule(__name__, globals()["__file__"], _import_structure, module_spec=__spec__)






def 		A_	(							snake_case							:				Union[str, Any]	, snake_case							:				Tuple	, snake_case							:				Optional[Any]	) ->      Union[str, Any]:



						'''simple docstring'''

						assert b != 0, "This cannot accept modulo that is == 0"
						if n == 0:
												return 1

						if n % 2 == 1:
												return (bin_exp_mod(snake_case	, n - 1	, snake_case	) * a) % b

						__UpperCamelCase       					=     bin_exp_mod(snake_case	, n / 2	, snake_case	)
						return (r * r) % b


if __name__ == "__main__":
				try:
								lowercase__							:							Dict													=     int(input("Enter Base : ").strip())
								lowercase__							:							Dict													=     int(input("Enter Power : ").strip())
								lowercase__							:							Dict													=     int(input("Enter Modulo : ").strip())
				except ValueError:
								print("Invalid literal for integer")

				print(bin_exp_mod(BASE, POWER, MODULO))




