from qiskit import QuantumCircuit,Aer,execute
from qiskit.circuit import Gate
from math import pi,sqrt

qc = QuantumCircuit(2)
qc.x(0)
qc.h([0,1])
qc.barrier()
qc.h([0,1])
qc.cx(0,1)
qc.cx(1,0)
qc.cx(0,1)
qc.h([0,1])
qc.draw('mpl')

backend_s = Aer.get_backend('statevector_simulator')
job = execute(qc,backend_s).result()
sv = job.get_statevector()

from qiskit_textbook.tools import array_to_latex

array_to_latex(sv)

import qiskit
qiskit.__qiskit_version__

