This article will cover the syntax of the ‘let’ regular script statement

The let statement is used for assigning values to variables. The expression assigned to the variable is calculated before it is assigned to the variable specified. 

Statement syntax

Let variablename=expression;

VariablenameThe name of the variable. This is the name used to call the variable as required.
ExpressionThe expression to be evaluated and assigned to the variable.

Example

A variable is created to hold the current date.

Result

A variable holding today’s date is created.