

"""simple docstring"""




from __future__ import annotations
def   lowerCAmelCase						(					__UpperCamelCase							,    __UpperCamelCase							,    __UpperCamelCase							,    __UpperCamelCase      ):  # noqa: E741
 '''simple docstring'''





 while r - l > 1:
  UpperCAmelCase__					:  List[str]					   =					(l + r) // 2
  if v[m] >= key:
   UpperCAmelCase__					:  List[str]					   =					m
  else:
   UpperCAmelCase__					:  Optional[Any]					   =					m  # noqa: E741
 return r
def   lowerCAmelCase						(					__UpperCamelCase      ):
 '''simple docstring'''





 if len(__UpperCamelCase      ) == 0:
  return 0

 UpperCAmelCase__					:  Optional[Any]					   =					[0] * len(__UpperCamelCase      )
 UpperCAmelCase__					:  Any					   =					1

 UpperCAmelCase__					:  str					   =					v[0]

 for i in range(1							,    len(__UpperCamelCase      )      ):
  if v[i] < tail[0]:
   UpperCAmelCase__					:  Union[str, Any]					   =					v[i]
  elif v[i] > tail[length - 1]:
   UpperCAmelCase__					:  Any					   =					v[i]
   length += 1
  else:
   UpperCAmelCase__					:  List[Any]					   =					v[i]

 return length


if __name__ == "__main__":
      import doctest

      doctest.testmod()








"""simple docstring"""




# tests directory-specific settings - this file is run automatically
# by pytest before any tests are run

import sys
import warnings
from os.path import abspath, dirname, join


# allow having multiple repository checkouts and not needing to remember to rerun
# 'pip install -e .[dev]' when switching between checkouts and running tests.
__UpperCAmelCase =				abspath(join(dirname(dirname(__file__)), 'src'))
sys.path.insert(1, git_repo_path)

# silence FutureWarning warnings in tests since often we can't act on them until
# they become normal warnings - i.e. the tests still need to test the current functionality
warnings.simplefilter(action='ignore', category=FutureWarning)
def   lowerCAmelCase						(					__UpperCamelCase      ):
 '''simple docstring'''





 from diffusers.utils.testing_utils import pytest_addoption_shared

 pytest_addoption_shared(__UpperCamelCase      )




def   lowerCAmelCase						(					__UpperCamelCase      ):
 '''simple docstring'''





 from diffusers.utils.testing_utils import pytest_terminal_summary_main

 UpperCAmelCase__					:  Optional[Any]					   =					terminalreporter.config.getoption("""--make-reports"""      )
 if make_reports:
  pytest_terminal_summary_main(__UpperCamelCase							,    id=__UpperCamelCase      )





