The main requirement is to obtain the set-intersection of the rows:

   rowintersection =: ([-.-.)&~./

(The &~. isn't essential,  but it will save space for large arrays with significant repetition.)


(Drafting this,  I see Raul's beaten me to it,  though he didn't include the &~. !!!)


Also,

    colintersection =: rowintersection@:|:



Cheers,


Mike




On 01/09/2017 07:48, Skip Cave wrote:
  ]a =: 6 12$ ?72$10



---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to