We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent eef1767 commit 74f8efbCopy full SHA for 74f8efb
examples/fizz_buzz.ark
@@ -0,0 +1,13 @@
1
+(import std.Range)
2
+
3
+(let r (range:range 0 100))
4
+(range:forEach
5
+ r
6
+ (fun (e)
7
+ (if (= 0 (mod e 15))
8
+ (print "FizzBuzz")
9
+ (if (= 0 (mod e 3))
10
+ (print "Fizz")
11
+ (if (= 0 (mod e 5))
12
+ (print "Buzz")
13
+ (print e))))))
examples/show_ascii_table.ark
@@ -0,0 +1,15 @@
+(mut i 0)
+(while (< i 16) {
+ (mut j (+ 32 i))
+ (while (< j 128) {
+ (let k
+ (if (= 32 j)
+ "Spc"
+ (if (= 127 j)
+ "Del"
+ (string:chr j))))
+ (puts (string:format "{:3} : {:<3}" j k))
+ (set j (+ 16 j)) })
+ (print "")
14
15
+ (set i (+ 1 i)) })
0 commit comments