Skip to content

Instantly share code, notes, and snippets.

@gvvynplaine
Created May 15, 2020 09:50
Show Gist options
  • Save gvvynplaine/1e42f48c76257ae2867016ce729ffe8c to your computer and use it in GitHub Desktop.
Save gvvynplaine/1e42f48c76257ae2867016ce729ffe8c to your computer and use it in GitHub Desktop.
quantum superposition and entanglement
OPENQASM 2.0;
include "qelib1.inc";
gate nG0 ( param ) q {
h q;
}
gate nG1 ( param ) q {
h q;
}
qreg q[2];
creg c[2];
h q[0];
cx q[0],q[1];
h q[0];
measure q[0] -> c[0];
measure q[1] -> c[1];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment