aboutsummaryrefslogtreecommitdiff
path: root/examples/test.sloth
diff options
context:
space:
mode:
authorCody <cody@codyq.dev>2023-02-27 12:14:16 -0600
committerCody <cody@codyq.dev>2023-02-27 12:14:16 -0600
commite4199d2837d2179f17e97b8d50366d96c8babded (patch)
treee07543001ba1aa7e05ff8b289b4d3154d7123fd6 /examples/test.sloth
parentf464fe944808df7865262962b8231c0009874692 (diff)
downloadsloth-e4199d2837d2179f17e97b8d50366d96c8babded.tar.gz
Added while loops & guessing game
Diffstat (limited to 'examples/test.sloth')
-rw-r--r--examples/test.sloth16
1 files changed, 0 insertions, 16 deletions
diff --git a/examples/test.sloth b/examples/test.sloth
deleted file mode 100644
index 7104593..0000000
--- a/examples/test.sloth
+++ /dev/null
@@ -1,16 +0,0 @@
-print("Pick a number between 1 and 5: ");
-
-val human = parse_int(readln());
-val computer = random(1, 5);
-
-if human == computer {
- println("You guessed the same number as me!");
-}
-
-if human > computer {
- println("Your guess was too high.");
-}
-
-if human < computer {
- println("Your guess was too low.");
-}