|q⟩ Bad Qubits

← Question Bank

Multiple choice
For this circuit, what is the probability that measuring all 3 qubits yields exactly |111⟩ (qubit 0 leftmost)?
⚛ The apparatus
const c = circuit(3);
c.h(0); c.h(1); c.h(2);

// Oracle: phase-flip |000>
c.x(0); c.x(1); c.x(2);
c.h(2); c.ccx(0, 1, 2); c.h(2);
c.x(0); c.x(1); c.x(2);

// Oracle: phase-flip |111>
c.h(2); c.ccx(0, 1, 2); c.h(2);

// Diffuser
c.h(0); c.h(1); c.h(2);
c.x(0); c.x(1); c.x(2);
c.h(2); c.ccx(0, 1, 2); c.h(2);
c.x(0); c.x(1); c.x(2);
c.h(0); c.h(1); c.h(2);

return c;

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