"""simple docstring"""



from __future__ import annotations

from itertools import permutations
from random import randint
from timeit import repeat



def    SCREAMING_SNAKE_CASE       (     ):
     __snake_case				=							[randint(-10_00,      10_00) for i in range(10)]
     __snake_case				=							randint(-50_00,      50_00)
     return (arr, r)


__lowercase		:		str														=							make_dataset()



def    SCREAMING_SNAKE_CASE       (     snake_case,      snake_case):
     for triplet in permutations(UpperCamelCase__,      3):
          if sum(UpperCamelCase__) == target:
               return tuple(sorted(UpperCamelCase__))
     return (0, 0, 0)



def    SCREAMING_SNAKE_CASE       (     snake_case,      snake_case):
     arr.sort()
     __snake_case				=							len(UpperCamelCase__)
     for i in range(n - 1):
          __snake_case				=							i + 1, n - 1
          while left < right:
               if arr[i] + arr[left] + arr[right] == target:
                    return (arr[i], arr[left], arr[right])
               elif arr[i] + arr[left] + arr[right] < target:
                    left += 1
               elif arr[i] + arr[left] + arr[right] > target:
                    right -= 1
     return (0, 0, 0)



def    SCREAMING_SNAKE_CASE       (     ):
     __snake_case				=							"""
from __main__ import dataset, triplet_sum1, triplet_sum2
"""
     __snake_case				=							"""
triplet_sum1(*dataset)
"""
     __snake_case				=							"""
triplet_sum2(*dataset)
"""
     __snake_case				=							repeat(setup=UpperCamelCase__,      stmt=UpperCamelCase__,      repeat=5,      number=1_00_00)
     __snake_case				=							repeat(setup=UpperCamelCase__,      stmt=UpperCamelCase__,      repeat=5,      number=1_00_00)
     return (min(UpperCamelCase__), min(UpperCamelCase__))


if __name__ == "__main__":
       from doctest import testmod

       testmod()
       __lowercase		:		int														=							solution_times()
       print(F"""The time for naive implementation is {times[0]}.""")
       print(F"""The time for optimized implementation is {times[1]}.""")
"""simple docstring"""



import qiskit





def    SCREAMING_SNAKE_CASE       (     snake_case,      snake_case):
     __snake_case				=							qiskit.Aer.get_backend('''aer_simulator''')

     # Create a Quantum Circuit acting on the q register
     __snake_case				=							qiskit.QuantumCircuit(snake_case,      snake_case)

     # Map the quantum measurement to the classical bits
     circuit.measure([0],      [0])

     # Execute the circuit on the simulator
     __snake_case				=							qiskit.execute(snake_case,      snake_case,      shots=10_00)

     # Return the histogram data of the results of the experiment.
     return job.result().get_counts(snake_case)


if __name__ == "__main__":
       print(F"""Total count for various states are: {single_qubit_measure(1, 1)}""")