Anonymous user
Create a two-dimensional array at runtime: Difference between revisions
Create a two-dimensional array at runtime (view source)
Revision as of 21:30, 9 June 2010
, 14 years ago→{{header|AppleScript}}
(→{{header|OCaml}}: bigarray) |
|||
Line 33:
print (array[1,1])
)</lang>
=={{header|APL}}==
Arrays are an integral part of APL. Array size, shape, and data type can be easily manipulated at runtime.
<lang APL>array←m n ⍴ 0 ⍝ array of zeros with shape of m by n.
array[1;1]←73 ⍝ assign a value to location 1;1.
array[1;1] ⍝ read the value back out
⎕ex 'array' ⍝ erase the array
</lang>
=={{header|AppleScript}}==
|