from qiskit import *
%matplotlib inline

qc = QuantumRegister(size=2)
circuit = QuantumCircuit(qc)
circuit.draw(output='mpl')

circuit.cx(control_qubit=qc[0],target_qubit=qc[1])
circuit.cx(control_qubit=qc[1],target_qubit=qc[0])
circuit.cx(control_qubit=qc[0],target_qubit=qc[1])
circuit.draw(output='mpl')