From 5bddf4f8284696f9666bb99c1ee9536dd24395b9 Mon Sep 17 00:00:00 2001 From: Paulyn <87922888+JakeOJeff@users.noreply.github.com> Date: Mon, 24 Nov 2025 00:36:53 +0530 Subject: [PATCH] Setting Switch Statements --- guide.md | 66 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 guide.md diff --git a/guide.md b/guide.md new file mode 100644 index 0000000..d09a476 --- /dev/null +++ b/guide.md @@ -0,0 +1,66 @@ +# Guide +This is a temporary guide on how the language works + +## Variable Initialization + +### Global Variables + +``` + x = 10 + x = x + 5 +``` + +### Local Variables + +``` + nat y = x + 20 + nat z = 20 +``` + +## Functions + +``` + call funcName(args) + [body] + done +``` + +``` + funcName(val) +``` + +## If Statements + +### Normal Statements + +``` + if (statement) + [body] + done +``` + +### Else and Else If Statements + +``` + if (statement1) + [body] + elif (statement2) + [body] + else + [body] + done +``` + +## Loops + +### While Loops + +``` + when (statement) + [body] + done +``` + + +## Switch Statements +