aboutsummaryrefslogtreecommitdiff
path: root/spec/inputs
diff options
context:
space:
mode:
authorLi Jin <dragon-fly@qq.com>2021-02-15 13:17:47 +0800
committerLi Jin <dragon-fly@qq.com>2021-02-15 13:17:47 +0800
commitc6e90a619d4bf027fa0c9fd81c71a6227b8cb3ca (patch)
tree31d0b1b50b718f0aa4e4c67a368c5acbf9e7e146 /spec/inputs
parentc3a389e2f9f53fb3e3e70a325bf42c8ce02a0b82 (diff)
downloadyuescript-c6e90a619d4bf027fa0c9fd81c71a6227b8cb3ca.tar.gz
yuescript-c6e90a619d4bf027fa0c9fd81c71a6227b8cb3ca.tar.bz2
yuescript-c6e90a619d4bf027fa0c9fd81c71a6227b8cb3ca.zip
fix some ambiguous syntax.
Diffstat (limited to 'spec/inputs')
-rw-r--r--spec/inputs/goto.mp6
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/inputs/goto.mp b/spec/inputs/goto.mp
index 3410ca3..1197251 100644
--- a/spec/inputs/goto.mp
+++ b/spec/inputs/goto.mp
@@ -7,7 +7,7 @@ do
7 ::done:: 7 ::done::
8 8
9do 9do
10 for z = 1, 10 for y = 1, 10 for x = 1, 10 10 for z = 1, 10 do for y = 1, 10 do for x = 1, 10
11 if x^2 + y^2 == z^2 11 if x^2 + y^2 == z^2
12 print 'found a Pythagorean triple:', x, y, z 12 print 'found a Pythagorean triple:', x, y, z
13 goto done 13 goto done
@@ -15,7 +15,7 @@ do
15 15
16do 16do
17 for z = 1, 10 17 for z = 1, 10
18 for y = 1, 10 for x = 1, 10 18 for y = 1, 10 do for x = 1, 10
19 if x^2 + y^2 == z^2 19 if x^2 + y^2 == z^2
20 print 'found a Pythagorean triple:', x, y, z 20 print 'found a Pythagorean triple:', x, y, z
21 print 'now trying next z...' 21 print 'now trying next z...'
@@ -24,7 +24,7 @@ do
24 24
25do 25do
26 ::redo:: 26 ::redo::
27 for x = 1, 10 for y = 1, 10 27 for x = 1, 10 do for y = 1, 10
28 if not f x, y then goto continue 28 if not f x, y then goto continue
29 if not g x, y then goto skip 29 if not g x, y then goto skip
30 if not h x, y then goto redo 30 if not h x, y then goto redo