OPENQASM 3.0; include "stdgates.inc"; // From the example's text: x on each qubit (custom X) with one control given after its target, as the schema orders a controlled gate's qubits: qubit k + 1 controls qubit k. qubit[5] q; bit[5] c; h q[0]; cx q[1], q[0]; cx q[2], q[1]; cx q[3], q[2]; cx q[4], q[3]; c = measure q;