
"""simple docstring"""

import sys

sys.set_int_max_str_digits(0)  # type: ignore






def 				A		(							snake_case :int						) ->      List[str]:
 __UpperCamelCase							    =			[0] * 1_1
 __UpperCamelCase							    =			[0] * 1_1

 # mark last 9 numbers
 for _ in range(9						):
  __UpperCamelCase							    =			1
  __UpperCamelCase							    =			number // 1_0
 # 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(lowerCAmelCase__						)[:9]						)

 for _ in range(9						):
  __UpperCamelCase							    =			1
  __UpperCamelCase							    =			number // 1_0

 # check first 9 numbers for pandigitality

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






def 				A		(							snake_case :int						) ->      Union[str, Any]:
 __UpperCamelCase							    =			[0] * 1_1

 # mark last 9 numbers
 for _ in range(9						):
  __UpperCamelCase							    =			1
  __UpperCamelCase							    =			number // 1_0
 # 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		(							) ->      Any:
 __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] * 1_0_0_0_0_0_0
 __UpperCamelCase							    =			1_0_0_0_0_0_0_0_0_0

 for x in range(1_0_0_0_0_0_0						):
  __UpperCamelCase							    =			(aa + ba) % m
  __UpperCamelCase							    =			ba % m
  __UpperCamelCase							    =			ca % m
  if checka(lowerCAmelCase__						):
   __UpperCamelCase							    =			1

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


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





import unittest

import torch

from diffusers import DDIMScheduler, TextToVideoZeroPipeline
from diffusers.utils import load_pt, require_torch_gpu, slow

from ..test_pipelines_common import assert_mean_pixel_difference







@slow
@require_torch_gpu
class 							lowercase						(   unittest.TestCase						):




							def 					A__ (							self):
												lowercase		      =		'''runwayml/stable-diffusion-v1-5'''
												lowercase		      =		TextToVideoZeroPipeline.from_pretrained(A__  ,torch_dtype=torch.floataa).to('''cuda''')
												lowercase		      =		DDIMScheduler.from_config(pipe.scheduler.config)
												lowercase		      =		torch.Generator(device='''cuda''').manual_seed(0)

												lowercase		      =		'''A bear is playing a guitar on Times Square'''
												lowercase		      =		pipe(prompt=A__  ,generator=A__).images

												lowercase		      =		load_pt(
												    '''https://huggingface.co/datasets/hf-internal-testing/diffusers-images/resolve/main/text-to-video/A bear is playing a guitar on Times Square.pt''')

												assert_mean_pixel_difference(A__  ,A__)




