Skip to content

Commit 92e8b17

Browse files
committed
disambiguating slices by making slices use backslashes instead of semicolons, updated readme and index.html to reflect new changes to syntax.
1 parent ab9ab5c commit 92e8b17

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

examples/factorial.funk

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
`5..1` t1t
22

3-
factorial(x) = ? x > 1 => x * factorial(x - 1) : 1
3+
factorial(x) = ? x > 1 => x * factorial(x - 1) : 1
44

5-
factorial(x).step(5)
6-
print(x:5)
5+
factorial(x).step(5) // Step through 5 times
6+
print(x:1)

examples/slices.funk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
`1..9` t3t
22

3-
f(x) = x ; x + 1 ; x + 2
3+
f(x) = x \ x + 1 \ x + 2
44
f(x).step(2)
55
print(x:7)

index.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -448,8 +448,8 @@ <h3>Factorial - (factorial.funk)</h3>
448448

449449
factorial(x) = ? x > 1 => x * factorial(x - 1) : 1
450450

451-
factorial(x).step(5)
452-
print(x:5)</code></pre>
451+
factorial(x).step(5) // Step through 5 times
452+
print(x:1)</code></pre>
453453
<div class="output">
454454
<div class="output-title">Output:</div>
455455
<pre>5
@@ -519,7 +519,7 @@ <h3>Slice Example - (slices.funk)</h3>
519519
<div class="example">
520520
<pre><code>`1..9` t3t
521521

522-
f(x) = x ; x + 1 ; x + 2
522+
f(x) = x \ x + 1 \ x + 2
523523
f(x).step(2)
524524
print(f(x):7)</code></pre>
525525
<div class="output">

0 commit comments

Comments
 (0)