





'''simple docstring'''




import math

import qiskit
from qiskit import Aer, ClassicalRegister, QuantumCircuit, QuantumRegister, execute





def      __lowerCamelCase       (	__lowerCAmelCase    :				Union[str, Any] = 1	,  __lowerCAmelCase    :				List[str] = 1						)						->   qiskit.result.counts.Counts:
   if isinstance(__lowerCAmelCase	,  __lowerCAmelCase						) or isinstance(__lowerCAmelCase	,  __lowerCAmelCase						):
      raise TypeError("""inputs must be integers."""						)
   if (bit_a < 0) or (bit_a < 0):
      raise ValueError("""inputs must be positive."""						)
   if (math.floor(__lowerCAmelCase						) != bit_a) or (math.floor(__lowerCAmelCase						) != bit_a):
      raise ValueError("""inputs must be exact integers."""						)
   if (bit_a > 1) or (bit_a > 1):
      raise ValueError("""inputs must be less or equal to 1."""						)

   # build registers
   snake_case      		=					QuantumRegister(2	,  """qr"""						)
   snake_case      		=					ClassicalRegister(2	,  """cr"""						)

   snake_case      		=					QuantumCircuit(__lowerCAmelCase	,  __lowerCAmelCase						)

   # entanglement the qubits
   quantum_circuit.h(1						)
   quantum_circuit.cx(1	,  0						)

   # send the information
   snake_case      		=					str(__lowerCAmelCase						) + str(__lowerCAmelCase						)

   if c_information == "11":
      quantum_circuit.x(1						)
      quantum_circuit.z(1						)
   elif c_information == "10":
      quantum_circuit.z(1						)
   elif c_information == "01":
      quantum_circuit.x(1						)
   else:
      quantum_circuit.i(1						)

   # unentangled the circuit
   quantum_circuit.cx(1	,  0						)
   quantum_circuit.h(1						)

   # measure the circuit
   quantum_circuit.measure(__lowerCAmelCase	,  __lowerCAmelCase						)

   snake_case      		=					Aer.get_backend("""aer_simulator"""						)
   snake_case      		=					execute(__lowerCAmelCase	,  __lowerCAmelCase	,  shots=10_00						)

   return job.result().get_counts(__lowerCAmelCase						)


if __name__ == "__main__":
 print(F"""Counts for classical state send: {superdense_coding(1,1)}""")





'''simple docstring'''






from .hash_table import HashTable
from .number_theory.prime_numbers import is_prime, next_prime




class 		a__				(							a__  ):





							'''simple docstring'''






							def __init__(		self					,    *lowerCamelCase_					,    **lowerCamelCase_   )       ->							Optional[int]:
														super().__init__(*lowerCamelCase_					,    **lowerCamelCase_   )







							def   __SCREAMING_SNAKE_CASE							(		self					,    lowerCamelCase_					,    lowerCamelCase_   )       ->							Optional[int]:
														lowerCAmelCase__          =	(
														    next_prime(value % self.size_table   )
														    if not is_prime(value % self.size_table   )
														    else value % self.size_table
														)  # gt = bigger than
														return next_prime_gt - (data % next_prime_gt)







							def   __SCREAMING_SNAKE_CASE							(		self					,    lowerCamelCase_					,    lowerCamelCase_					,    lowerCamelCase_   )       ->							Optional[int]:
														return (increment * self.__hash_function_a(lowerCamelCase_					,    lowerCamelCase_   )) % self.size_table







							def   __SCREAMING_SNAKE_CASE							(		self					,    lowerCamelCase_					,    lowerCamelCase_=None   )       ->							Any:
														lowerCAmelCase__          =	1
														lowerCAmelCase__          =	self.hash_function(lowerCamelCase_   )

														while self.values[new_key] is not None and self.values[new_key] != key:
																					lowerCAmelCase__          =	(
																					    self.__hash_double_function(lowerCamelCase_					,    lowerCamelCase_					,    lowerCamelCase_   )
																					    if self.balanced_factor() >= self.lim_charge
																					    else None
																					)
																					if new_key is None:
																												break
																					else:
																												i += 1

														return new_key