SunSed variables are containers for storing values (data). They may hold any of SunSed supported data types (string, integer, arrays and etc.)

Creating Variables

Variables should always start with a $ sign.

The name of the variable follows the $, and it may start either with an underscore or a letter, never a number. After the first character, the remainder of the variable name may contain numbers too.

$x = 100
$_user_name = "Howl"
$x_of_200 = [200, 400, 600, 800]

NOTE: Variable names that start with a number are invalid.

# invalid variable declaration
$1 = 1

Variable names are case sensitive, meaning you may use $user, $USER, or $UsEr, however, they are treated as different variables.

Copyright © SunSed LLC 2013-2022 All rights reserved.