OPENQASM 3.1; // Controls on any gate: a rotation under two controls, and a negative control. qubit[3] q; x q[0]; x q[1]; ctrl(2) @ ry(pi / 3) q[0], q[1], q[2]; negctrl @ x q[2], q[0];