|q⟩ Bad Qubits

← Question Bank

Multiple choice
Run this circuit, then measure. With what probability do you get |01⟩?
⚛ The apparatus
// Start from |00>. Flip qubit 1 to reach |01>.
// Hadamard on qubit 0 gives (|01> + |11>)/sqrt(2).
// CNOT(0->1) gives (|01> + |10>)/sqrt(2) (the symmetric combination).
// A Z on qubit 0 flips the sign of the |1..> branch, turning + into -,
// yielding (|01> - |10>)/sqrt(2).
const c = circuit(2);
c.x(1);
c.h(0);
c.cx(0, 1);
c.z(0);
return c;

Commit your prediction for P(|01⟩) — then run it.