Creating an Array: Difference between revisions

Content added Content deleted
(→‎{{header|J}}: a bit more explanation)
Line 289: Line 289:
"Creating an array" is topic seldom discussed in J as <i>every</i> verb takes array argument(s)
"Creating an array" is topic seldom discussed in J as <i>every</i> verb takes array argument(s)
and returns an array result. (That is, <i>everything</i> creates an array.)
and returns an array result. (That is, <i>everything</i> creates an array.)
For example:


a=: 3 4 $ 3 1 4 1 5 9 2 6 5 3 5 8 NB. make a 3-by-4 table
a=: 3 4 $ 3 1 4 1 5 9 2 6 5 3 5 8 NB. make a 3-by-4 table
Line 309: Line 310:
ysom
ysom
yran
yran

Both the<tt> a+b </tt>and the<tt> |."1 c </tt>expressions create arrays.


=={{header|Java}}==
=={{header|Java}}==