



"""simple docstring"""






import sys
import turtle






def 	snake_case_  (				A_ :		tuple[float, float],    A_ :		tuple[float, float]						):


       '''simple docstring'''





       return (pa[0] + pa[0]) / 2, (pa[1] + pa[1]) / 2






def 	snake_case_  (				A_ :		tuple[float, float],    A_ :		tuple[float, float],    A_ :		tuple[float, float],    A_ :		int,    ):


       '''simple docstring'''





       my_pen.up()
       my_pen.goto(vertexa[0],    vertexa[1]						)
       my_pen.down()
       my_pen.goto(vertexa[0],    vertexa[1]						)
       my_pen.goto(vertexa[0],    vertexa[1]						)
       my_pen.goto(vertexa[0],    vertexa[1]						)

       if depth == 0:
              return

       triangle(A_,    get_mid(A_,    A_						),    get_mid(A_,    A_						),    depth - 1						)
       triangle(A_,    get_mid(A_,    A_						),    get_mid(A_,    A_						),    depth - 1						)
       triangle(A_,    get_mid(A_,    A_						),    get_mid(A_,    A_						),    depth - 1						)


if __name__ == "__main__":
   if len(sys.argv) != 2:
      raise ValueError(
          '''Correct format for using this script: '''
          '''python fractals.py <int:depth_for_fractal>'''
      )
   lowerCAmelCase__      =    turtle.Turtle()
   my_pen.ht()
   my_pen.speed(5)
   my_pen.pencolor('''red''')

   lowerCAmelCase__      =    [(-175, -125), (0, 175), (175, -125)]  # vertices of triangle
   triangle(vertices[0], vertices[1], vertices[2], int(sys.argv[1]))







"""simple docstring"""






import argparse


lowerCAmelCase__      =    '''docs/source/_static/js/custom.js'''






def 	snake_case_  (				A_ :		List[str]						):


       '''simple docstring'''





       with open(A_,    encoding='''utf-8''',    newline='''\n'''						) as f:
              _lowerCamelCase						:    int         =			f.readlines()
       _lowerCamelCase						:    List[str]         =			0

       # First let's put the right version
       while not lines[index].startswith('''const stableVersion ='''						):
              index += 1
       _lowerCamelCase						:    List[Any]         =			F'''const stableVersion = "v{version}"\n'''

       # Then update the dictionary
       while not lines[index].startswith('''const versionMapping = {'''						):
              index += 1

       # We go until the end
       while not lines[index].startswith('''}'''						):
              index += 1
       # We add the new version at the end
       lines[index - 1] += F'''    "v{version}": "v{version}",\n'''

       with open(A_,    '''w''',    encoding='''utf-8''',    newline='''\n'''						) as f:
              f.writelines(A_						)


if __name__ == "__main__":
   lowerCAmelCase__      =    argparse.ArgumentParser()
   parser.add_argument('''--version''', help='''Release version.''')
   lowerCAmelCase__      =    parser.parse_args()
   update_custom_js(args.version)


