C2: Controlled-T

Time Limit: 3 seconds

Memory Limit: 512 MiB

Score: 300 points

Problem Statement

Using only Clifford gates, TT gate, and CCXCCX gate,

implement an oracle UU satisfying the following on a quantum circuit qc\mathrm{qc} with 33 qubits.

For any quantum state ψ2\ket{\psi}_{2},

ψ20U(CT(0,1)I)ψ20\ket{\psi}_{2} \ket{0} \xrightarrow{U} (CT(0, 1) \otimes I) \ket{\psi}_{2} \ket{0}

Here, CT(0,1)CT(0, 1) denotes the controlled-TT gate with qubit 1 as the control qubit and qubit 2 as the target qubit.

Constraints

  • Only Clifford gates, TT gate, and CCXCCX gate can be used.
  • The submitted code must follow the specified format:
from qiskit import QuantumCircuit
 
 
def solve() -> QuantumCircuit:
    qc = QuantumCircuit(3)
    # Write your code here:
 
    return qc

Hints

Open
  • (CT(0,1)I)ψ20(CT(0, 1) \otimes I) \ket{\psi}_{2} \ket{0} simply means applying CT(0,1)CT(0, 1) to ψ2\ket{\psi}_{2}.

Please sign in to submit your answer.