A Quil interpreter written in python 🐍
Simply run the interpreter.py file, and the console will expect input from stdin.
python interpreter.pyUse Ctrl-D to stop interpreting and output probablitites.
Additionally we have provided some quil programs for testing, in the quil_tests folder. Run the scripts like so
cat quil_tests/superdense_coding.quil | python interpreter.pyYou may use the following quantum gates:
HXYZICNOTMEASURE
You can declare classical memory with DECLARE and control the flow of operations with LABELs and JUMPS
DEFGATE and DEFCIRCUIT, as well as most operations on classical memory (ADD, MOV, MUL)