listA ~: listB
will produce a boolean list you can use to target the items that aren't equal

Is your problem with counting non-zero list items to do with tolerance
or simply how to do it
+/ listA ~: 0    NB. counts non-zero list items

On Tue, Jul 12, 2011 at 10:48 PM, David Vaughan
<[email protected]> wrote:
> What is the best approach to compare the contents of lists? What I want to do 
> is the equivalent of:
>
> if (listA[i]!=listB[i])
>
> In C.
>
> Also I've been having trouble trying to count nonzero list items.
>
> Thanks.
>
> ___________________________
>
> David Vaughan
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to