My first idea was to use ^: . But I am unable to get a solution. None of the posted solutions use ^: either. Just wondering whether ^: can help here.
On Thu, 16 Jan 2020, 12:36 'robert therriault' via Programming, < programm...@jsoftware.com> wrote: > It is too late, considering the result is not the one that you requested! > > Anyway I would use a numerical approach something like the incorrect one > that I just posted. > > Sheepishly - Cheers, bob > > > On Jan 15, 2020, at 23:03, 'robert therriault' via Programming < > programm...@jsoftware.com> wrote: > > > > Hi Skip, > > > > A late snowy night silly approach > > > > ]a=.20#1 > > 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 > > f1=. *@(3&|)@:i.@:# NB. mod 3 non-zeros > > f1 a > > 0 1 1 0 1 1 0 1 1 0 1 1 0 1 1 0 1 1 0 1 > > f2=. -.@*@(2&|)@:i.@:# NB. mod 2 zeros > > f2 a > > 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 > > (f1 *: f2) a NB. Not-And fork > > 1 1 0 1 0 1 1 1 0 1 0 1 1 1 0 1 0 1 1 1 > > f=. f1 *: f2 NB. requested result > > f a > > 1 1 0 1 0 1 1 1 0 1 0 1 1 1 0 1 0 1 1 1 > > > > Cheers, bob > > > > > >> On Jan 15, 2020, at 22:29, Skip Cave <s...@caveconsulting.com> wrote: > >> > >> ]a=.20#1 > > > > ---------------------------------------------------------------------- > > For information about J forums see http://www.jsoftware.com/forums.htm > > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm > ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm