



import sys

sys.set_int_max_str_digits(0)  # type: ignore







def 				A			(		__UpperCAmelCase	)       ->       bool:



						'''simple docstring'''






						UpperCAmelCase_     							=     [0] * 11
						UpperCAmelCase_     							=     [0] * 11

						# mark last 9 numbers
						for _ in range(9	):
												UpperCAmelCase_     							=     1
												UpperCAmelCase_     							=     number // 10
						# flag
						UpperCAmelCase_     							=     True

						# check last 9 numbers for pandigitality

						for x in range(9	):
												if not check_last[x + 1]:
																		UpperCAmelCase_     							=     False
						if not f:
												return f

						# mark first 9 numbers
						UpperCAmelCase_     							=     int(str(__UpperCAmelCase	)[:9]	)

						for _ in range(9	):
												UpperCAmelCase_     							=     1
												UpperCAmelCase_     							=     number // 10

						# check first 9 numbers for pandigitality

						for x in range(9	):
												if not check_front[x + 1]:
																		UpperCAmelCase_     							=     False
						return f







def 				A			(		__UpperCAmelCase	)       ->       bool:



						'''simple docstring'''






						UpperCAmelCase_     							=     [0] * 11

						# mark last 9 numbers
						for _ in range(9	):
												UpperCAmelCase_     							=     1
												UpperCAmelCase_     							=     number // 10
						# flag
						UpperCAmelCase_     							=     True

						# check last 9 numbers for pandigitality

						for x in range(9	):
												if not check_last[x + 1]:
																		UpperCAmelCase_     							=     False
						return f







def 				A			(		)       ->       int:



						'''simple docstring'''






						UpperCAmelCase_     							=     1
						UpperCAmelCase_     							=     1
						UpperCAmelCase_     							=     2
						# temporary Fibonacci numbers

						UpperCAmelCase_     							=     1
						UpperCAmelCase_     							=     1
						UpperCAmelCase_     							=     2
						# temporary Fibonacci numbers mod 1e9

						# mod m=1e9, done for fast optimisation
						UpperCAmelCase_     							=     [0] * 100_0000
						UpperCAmelCase_     							=     10_0000_0000

						for x in range(100_0000	):
												UpperCAmelCase_     							=     (aa + ba) % m
												UpperCAmelCase_     							=     ba % m
												UpperCAmelCase_     							=     ca % m
												if checka(__UpperCAmelCase	):
																		UpperCAmelCase_     							=     1

						for x in range(100_0000	):
												UpperCAmelCase_     							=     a + b
												UpperCAmelCase_     							=     b
												UpperCAmelCase_     							=     c
												# perform check only if in tocheck
												if tocheck[x + 3] and check(__UpperCAmelCase	):
																		return x + 3  # first 2 already done
						return -1


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










from typing import TYPE_CHECKING

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


UpperCamelCase_	       =   {"configuration_vit_hybrid": ["VIT_HYBRID_PRETRAINED_CONFIG_ARCHIVE_MAP", "ViTHybridConfig"]}

try:
							if not is_torch_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							UpperCamelCase_	       =   [
							    "VIT_HYBRID_PRETRAINED_MODEL_ARCHIVE_LIST",
							    "ViTHybridForImageClassification",
							    "ViTHybridModel",
							    "ViTHybridPreTrainedModel",
							]

try:
							if not is_vision_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							UpperCamelCase_	       =   ["ViTHybridImageProcessor"]


if TYPE_CHECKING:
							from .configuration_vit_hybrid import VIT_HYBRID_PRETRAINED_CONFIG_ARCHIVE_MAP, ViTHybridConfig

							try:
														if not is_torch_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .modeling_vit_hybrid import (
														    VIT_HYBRID_PRETRAINED_MODEL_ARCHIVE_LIST,
														    ViTHybridForImageClassification,
														    ViTHybridModel,
														    ViTHybridPreTrainedModel,
														)

							try:
														if not is_vision_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .image_processing_vit_hybrid import ViTHybridImageProcessor


else:
							import sys

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





