On 3/20/07, Geoff Canyon <[EMAIL PROTECTED]> wrote:
0 is the obvious answer, but there are other numbers that meet this criteria.
In addition to the one you called out (and its products with _1 and/or powers of ten), there's _. 0 _ and __ And each of these (except _.) can be meaningfully combined with any of the others using (j.)
1. So what _does_ =/ mean?
The monad, when applied to a list of length 2, returns 1 for atoms of each item which are equal and 0 otherwise. For longer lists it returns 1 for atoms which match the previous answer and 0 otherwise. This can be meaningful on binary lists of arbitrary length (exclusive-nor). The dyad compares all possible pairs between the two arguments.
3. Is there a way to compose my two lines above into a single command?
Sure! (Which two lines, specifically? And what do you intend for that command to do?) Did you mean: F=: (((1<])#@:~.@:(/:~@:":"0)@:((>:i.6)*]))+])^:_ ?
4. To avoid all the @: above, should I be looking for ways to turn it into forks and/or hooks?
The phrase A@:B in verbs A and B is equivalent to the fork [: A B -- Raul ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
