Hi Phil!
[EMAIL PROTECTED] wrote:
>Is it possible to use a variable to declare the size of an array ?
>
>my-array: array [3]
I see your problem right here. You don't declare arrays, you
create arrays, like this:
>> my-array: array 3
== [none none none]
Note that array is a function, which can take any integer or block
value as a parameter. To use a variable you do something like this:
>> j: 3 ; Assigning 3 to j (no declaration needed)
== 3
>> my-array: array j ; A function call, not a declaration
== [none none none]
>> my-array: array reduce [j] ; reduce needed to evaluate j here
== [none none none]
>> my-array: array [3 3] ; multidimensional
== [[none none none] [none none none] [none none none]]
See?
Brian