


import json
import sys







def  SCREAMING_SNAKE_CASE_		(    __A				:    int						,					__A				:    List[str]       )			->	List[str]:

       """simple docstring"""

       with open(__A						,					encoding='utf-8'       ) as f:
              a_      :	str							=						json.load(__A       )

       a_      :	Any							=						['<details>', '<summary>Show updated benchmarks!</summary>', ' ']

       for benchmark_name in sorted(__A       ):
              a_      :	Dict							=						results[benchmark_name]

              a_      :	Dict							=						benchmark_name.split('/'       )[-1]
              output_md.append(F"""### Benchmark: {benchmark_file_name}"""       )

              a_      :	List[str]							=						'| metric |'
              a_      :	Union[str, Any]							=						'|--------|'
              a_      :	Tuple							=						'| new / old (diff) |'
              for metric_name in sorted(__A       ):
                     a_      :	str							=						benchmark_res[metric_name]
                     a_      :	Optional[Any]							=						metric_vals['new']
                     a_      :	Optional[int]							=						metric_vals.get('old'						,					__A       )
                     a_      :	Any							=						metric_vals.get('diff'						,					__A       )

                     a_      :	Any							=						F""" {new_val:f}""" if isinstance(__A						,					(int, float)       ) else 'None'

                     if old_val is not None:
                            val_str += F""" / {old_val:f}""" if isinstance(__A						,					(int, float)       ) else "None"
                     if dif_val is not None:
                            val_str += F""" ({dif_val:f})""" if isinstance(__A						,					(int, float)       ) else "None"

                     title += " " + metric_name + " |"
                     lines += "---|"
                     value += val_str + " |"

              output_md += [title, lines, value, " "]

       output_md.append('</details>'       )

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


if __name__ == "__main__":
   UpperCAmelCase_   :				Dict						      = sys.argv[1]
   UpperCAmelCase_   :				Any						      = sys.argv[2]

   format_json_to_md(input_json_file, output_md_file)






def  SCREAMING_SNAKE_CASE_		(    __A				:    list       )			->	list:

       """simple docstring"""

       if len(__A       ) <= 1:
              return [tuple(__A       )]

       a_      :	Optional[Any]							=						[]

       def generate(__A				:    int						,					__A				:    list       ):
              a_      :	str							=						[0] * n
              res.append(tuple(__A       )       )

              a_      :	Optional[int]							=						0
              while i < n:
                     if c[i] < i:
                            if i % 2 == 0:
                                   a_							,	a_      :	Dict							=						arr[i], arr[0]
                            else:
                                   a_							,	a_      :	Union[str, Any]							=						arr[i], arr[c[i]]
                            res.append(tuple(__A       )       )
                            c[i] += 1
                            a_      :	Dict							=						0
                     else:
                            a_      :	Optional[Any]							=						0
                            i += 1

       generate(len(__A       )						,					__A       )
       return res


if __name__ == "__main__":
   UpperCAmelCase_   :				Union[str, Any]						      = input('Enter numbers separated by a comma:\n').strip()
   UpperCAmelCase_   :				Optional[Any]						      = [int(item) for item in user_input.split(',')]
   print(heaps(arr))


