Skip to content

Commit 5c5d8f4

Browse files
committed
Add python and wolfram support. Qiskit bug solved.
1 parent 8d28fad commit 5c5d8f4

21 files changed

+614
-25
lines changed

ex_python.pfcf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
~Python code~
2+
<python>
3+
print("hello world")
4+
</python>,

ex_python.txt

Whitespace-only changes.

ex_qiskit.pfcf

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
~Qiskit code~
2+
<qiskit>
3+
q0 q1
4+
X
5+
H
6+
.---X
7+
c1
8+
$host qasm_simulator
9+
$hist true
10+
$draw true
11+
</qiskit>,

ex_qiskit.txt

Whitespace-only changes.

ex_wolfram.pfcf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
~Wolfram code~
2+
<wolfram>
3+
Range[5]
4+
</wolfram>,

ex_wolfram.txt

Whitespace-only changes.

example.pfcf renamed to examples/example.pfcf

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Welcome to the future,:),|
1919
May 10 2021\, 13:45,
2020
by Eanorambuena,|
2121

22-
Add qiskit code like this:,|
22+
Add code like this:,|
2323
\<qiskit\>,
2424
q0 q1,
2525
X,
@@ -29,15 +29,12 @@ c1,
2929
$host qasm_simulator,
3030
$hist true,
3131
$draw true,
32-
\</qiskit\>,
33-
34-
<qiskit>
35-
q0 q1
36-
X
37-
H
38-
.---X
39-
c1
40-
$host qasm_simulator
41-
$hist true
42-
$draw true
43-
</qiskit>,
32+
\</qiskit\>\,,
33+
|
34+
\<python\>,
35+
print(\"hello world\"),
36+
\</python\>\,,
37+
|
38+
\<wolfram\>,
39+
Range[5],
40+
\</wolfram\>\,,

example.txt renamed to examples/example.txt

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Welcome to the future
1515
May 10 2021, 13:45
1616
by Eanorambuena
1717

18-
Add qiskit code like this:
18+
Add code like this:
1919

2020
<qiskit>
2121
q0 q1
@@ -26,4 +26,12 @@ c1
2626
$host qasm_simulator
2727
$hist true
2828
$draw true
29-
</qiskit>
29+
</qiskit>,
30+
31+
<python>
32+
print("hello world")
33+
</python>,
34+
35+
<wolfram>
36+
Range[5]
37+
</wolfram>,

main.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
from pfcf.read import read,executepfcf
22
from pfcf.utils import execute
3-
name="example"
4-
#execute("qiskit_compile")
5-
executepfcf(name)
3+
f1="example"
4+
f2="ex_qiskit"
5+
f3="ex_python"
6+
f4="ex_wolfram"
7+
#executepfcf(f4)
8+
execute("python_compile")
756 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)