PDocs 6: Variable Functions - GitbyteMaster/PRIME-Lang GitHub Wiki
Variable Functions
To use variable functions, you must create a variable. Here the the syntax:
var [name] = ([default value]);
You can renounce a variable by entering the variable as an argument with the miscellaneous datatype (>
). So if a variable is being used, it will be formatted as >[name]
. For example:
import system
var variable = ("hello world!");
system.display(>variable);
To change a variable's value, it is the same syntax as creating one.
var [exact name] = ([new value]);
To return one variable's value into another's, then just set the value of the first variable to the name of the second, like so:
var atom = ("1");
var molecule = (>atom);