at:tutorial:basic
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
at:tutorial:basic [2007/04/04 09:17] – * elisag | at:tutorial:basic [2007/04/04 11:01] – elisag | ||
---|---|---|---|
Line 33: | Line 33: | ||
==== Tables ==== | ==== Tables ==== | ||
- | As in Pico, indexed tables represent what other languages call arrays or lists. Tables indexes range from 1 to the size of the table. As variables, one can define, assign and refer to a table. Table definition is made also with the keyword def in the following form: | + | As in Pico, indexed tables represent what other languages call arrays or lists. Tables |
< | < | ||
def t[ < | def t[ < | ||
Line 41: | Line 41: | ||
>def z := 0 | >def z := 0 | ||
>>0 | >>0 | ||
- | > | + | > |
>>[1, 2, 3, 4, 5] | >>[1, 2, 3, 4, 5] | ||
</ | </ | ||
- | Table entries | + | Although there is no special constructor for definition of multidimensional tables, a table entry can contain another |
+ | |||
+ | < | ||
+ | >def vocals := [" | ||
+ | >> | ||
+ | > | ||
+ | >>[1, 2, [" | ||
+ | > | ||
+ | >>" | ||
+ | </ | ||
+ | |||
+ | As shown in the definition of the varible " | ||
+ | |||
+ | < | ||
+ | >[ 1, table, " | ||
+ | >>[1, [1, 2, [" | ||
+ | </code> | ||
==== Functions ==== | ==== Functions ==== |
at/tutorial/basic.txt · Last modified: 2020/02/09 22:05 by elisag