summaryrefslogtreecommitdiff
path: root/examples/control.fy
diff options
context:
space:
mode:
Diffstat (limited to 'examples/control.fy')
-rw-r--r--examples/control.fy32
1 files changed, 0 insertions, 32 deletions
diff --git a/examples/control.fy b/examples/control.fy
deleted file mode 100644
index 0deac78..0000000
--- a/examples/control.fy
+++ /dev/null
@@ -1,32 +0,0 @@
-#*
- * Examples of how to use control statements
- *#
-
-if 1 {
- say "if 1";
-}
-
-ifnot 0 == 1 {
- say "ifnot 0 == 1";
-}
-
-# Calculate 10!
-
-my n = 10, fac = 0;
-
-while n > 1 {
- ifnot fac {
- fac = 1;
- }
- say fac = (fac * n);
- decr n;
-}
-
-# Count up to 10
-
-n = 0;
-
-until n == 10 {
- say incr n;
-}
-