On Nov 23, 2007 6:28 PM, efittery <[EMAIL PROTECTED]> wrote:
> Still confused, but a little happier.
In another language, the values which in J are expressed as
,2
and
2
would probably have different data types.
The first expression returns a one element list (array) containing the number 2.
The second expression returns the number 2.
For example, in C, you might write:
int a[]= {2}; /* this is sort of like ,2 in J */
int b= 2; /* this is sort of like 2 in J */
When you add or subtract lists, they have to be the same length,
or you get a length error.
Values which do not have a shape automatically get replicated
as many times as needed.
(Actually, the rules are somewhat more useful than this. But
this should get you started.)
--
Raul
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm