![]() You can create two types of arrays: static and dynamic. The 0 index represents the first position, the 1 index represents the second position, and the 2 index represents the third position in the array. For example, if an array has three items, the indexes are 0, 1, and 2. The indexes always increment sequentially, starting from 0. The index number is an integer subscript that denotes an item's relative location in the list. ![]() The common name typically includes the prefix arr to denote that the variable contains data of the subtype Array. ![]() The common name is the name of the array variable. You reference each item in this list with a common name and index number. Think of an array as a list (e.g., a list of usernames). An array lets you address many data values through the same variable. Unlike all the other subtypes I showed you last month, an array can hold more than one value. Related: Understanding VBScript: Operators I also cover multidimensional and nested arrays. This month, I take a close look at what Array variables, or simply arrays, are and how you can create, fill, resize, traverse, erase, split, and join them. ![]() However, I intentionally didn't discuss an important subtype: Array. Last month, I discussed three basic syntax elements: variables, constants, and subtypes.
0 Comments
Leave a Reply. |