Skip to content

Commit 65973c1

Browse files
committed
updated documentation
1 parent d88df33 commit 65973c1

2 files changed

Lines changed: 10 additions & 4 deletions

File tree

docs/source/examples/create_and_measure.rst

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,15 @@ Create Qubit and Measure
44
.. code-block:: python
55
:linenos:
66
7-
import eqsn
7+
from eqsn import EQSN
8+
9+
# create the EQSN control object
10+
eqsn = EQSN()
811
912
# Create a Qubit with id A
1013
eqsn.new_qubit('A')
1114
1215
# Measure the Qubit with id A
1316
m = eqsn.measure('A')
14-
17+
1518
print("Measured Qubit with id 'A' with result %d." % m)

docs/source/examples/epr_creation.rst

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,10 @@ Below, an example is shown, how an EPR state can be created.
66
.. code-block:: python
77
:linenos:
88
9-
import eqsn
9+
from eqsn import EQSN
10+
11+
# create EQSN control object
12+
eqsn = EQSN()
1013
1114
# Create two Qubits, with ids A and B
1215
eqsn.new_qubit('A')
@@ -21,5 +24,5 @@ Below, an example is shown, how an EPR state can be created.
2124
# Measure both Qubits
2225
m1 = eqsn.measure('A')
2326
m2 = eqsn.measure('B')
24-
27+
2528
print("measured %d and %d." % (m1, m2))

0 commit comments

Comments
 (0)