From 1dac2376bce37f8c004c2857b60f4896ac8c15f9 Mon Sep 17 00:00:00 2001 From: TurdPooCharger <35666439+TurdPooCharger@users.noreply.github.com> Date: Tue, 29 May 2018 06:05:34 -0400 Subject: [PATCH] Updated Scripting: set & variables (markdown) --- Scripting:-set-&-variables.md | 35 ++++++++++++++++++++++++++++++----- 1 file changed, 30 insertions(+), 5 deletions(-) diff --git a/Scripting:-set-&-variables.md b/Scripting:-set-&-variables.md index 68c3f36..a1e1899 100644 --- a/Scripting:-set-&-variables.md +++ b/Scripting:-set-&-variables.md @@ -1,20 +1,45 @@ -`set` command +The `set` command defines or creates variables. Variables are fundamental to any programming. ## Usage ### Syntax & Example +`set ` -### User Defined Variables + +### User Defined Variables +**Example 1** +`set VARIABLE "argument"` +`echo $[VARIABLE]` + +**Output:** +> argument + +In this example, the value of the variable called **VARIABLE** is _argument_. The value is re-definable. + +`set VARIABLE "negotiate"` +`echo $[VARIABLE]` + +**Output:** +> negotiate + +Variables may hold empty or null placeholder values. + +`set VARIABLE ""` +`echo $[VARIABLE]` + +> ### Environmental Variables -These are variables with values that cannot redefined. +These are variables in which their values cannot redefined. **Example:** `echo $[GM9OUT]` -**Output:** 0:/gm9/out +**Output:** +> 0:/gm9/out `set GM9OUT "0:/gm9/in"` `echo $[GM9OUT]` -**Output:** 0:/gm9/out +**Output:** +> 0:/gm9/out ## Notes \ No newline at end of file