-
Notifications
You must be signed in to change notification settings - Fork 2
variables_types
bergsma edited this page Jul 31, 2014
·
2 revisions
HS uses variables for storing values. All variables have an identifier (name) , and a data type.
_Data type _specifies the internal storage format of the data. Variables can be declared with any of the available data types, and variables can easily be converted from one data type to another. Undeclared variables are created automatically with the list data type when they are initially assigned a value.
_Vectors _can be used to store indexed collections of the same data type, while lists and structures can be aggregates of arbitrary data types.
All variables may use subscript [ ] brackets to reference individual element values. Subscript indices start at zero.
For details on variables and data types, see:
- Identifiers: Rules for identifiers (names).
- Scope: Specifying the extent of variable use within a HS program.
- Literals: Ways of expressing constant values.
- Data Types: The data types available in HS.
- Declarations and Conversions Declaring variables and converting data types.
- Lists: Defining and using collections of variables in a list.
- Vectors: Defining and using indexed collections of related variables.
- Structures: Defining and using variable structures.
- References and Dereferencing How references and dereferencing are used.
- Hashed Variables: Creating hashed variables for more efficient access.