






"""simple docstring"""



class        __lowercase:






						def __init__(					self    ,						_SCREAMING_SNAKE_CASE)			->  None:




											"""simple docstring"""





											lowerCamelCase__				=data
											lowerCamelCase__				=42
											lowerCamelCase__				=42




def 						lowerCamelCase_				(  __A  :		Node			):
					lowerCamelCase__				=0
					lowerCamelCase__				=x




def 						lowerCamelCase_				(  __A  :		Node			,	__A  :		Node			):
					lowerCamelCase__				,     lowerCamelCase__				=find_set(__A			), find_set(__A			)
					if x == y:
										return

					elif x.rank > y.rank:
										lowerCamelCase__				=x
					else:
										lowerCamelCase__				=y
										if x.rank == y.rank:
															y.rank += 1




def 						lowerCamelCase_				(  __A  :		Node			):
					if x != x.parent:
										lowerCamelCase__				=find_set(x.parent			)
					return x.parent




def 						lowerCamelCase_				(  __A  :		Node			):
					lowerCamelCase__				=({0, 1, 2}, {3, 4, 5})
					for s in sets:
										if node.data in s:
															return s
					lowerCamelCase__				=f"{node.data} is not in {sets}"
					raise ValueError(__A			)




def 						lowerCamelCase_				(  ):
					lowerCamelCase__				=[Node(__A			) for i in range(6			)]
					for v in vertex:
										make_set(__A			)

					union_set(vertex[0]			,	vertex[1]			)
					union_set(vertex[1]			,	vertex[2]			)
					union_set(vertex[3]			,	vertex[4]			)
					union_set(vertex[3]			,	vertex[5]			)

					for nodea in vertex:
										for nodea in vertex:
															if find_python_set(__A			).isdisjoint(find_python_set(__A			)			):
																				assert find_set(__A			) != find_set(__A			)
															else:
																				assert find_set(__A			) == find_set(__A			)


if __name__ == "__main__":
						test_disjoint_set()







"""simple docstring"""



import math

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




def 						lowerCamelCase_				(  __A  :		int = 1			,	__A  :		int = 1			):
					if isinstance(__A			,	__A			) or isinstance(__A			,	__A			):
										raise TypeError('inputs must be integers.'			)
					if (bit_a < 0) or (bit_a < 0):
										raise ValueError('inputs must be positive.'			)
					if (math.floor(__A			) != bit_a) or (math.floor(__A			) != 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
					lowerCamelCase__				=QuantumRegister(2			,	'qr'			)
					lowerCamelCase__				=ClassicalRegister(2			,	'cr'			)

					lowerCamelCase__				=QuantumCircuit(__A			,	__A			)

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

					# send the information
					lowerCamelCase__				=str(__A			) + str(__A			)

					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(__A			,	__A			)

					lowerCamelCase__				=Aer.get_backend('aer_simulator'			)
					lowerCamelCase__				=execute(__A			,	__A			,	shots=1000			)

					return job.result().get_counts(__A			)


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