Very helpful! Thanks Raul. Linda
Sent from my Verizon, Samsung Galaxy smartphone -------- Original message -------- From: Raul Miller <rauldmil...@gmail.com> Date: 12/17/18 11:55 AM (GMT-05:00) To: Programming forum <programm...@jsoftware.com> Subject: Re: [Jprogramming] (no subject) When trying to understand an unfamiliar use of the insert adverb, it can be helpful to take the adverb out of the expression and instead do the insert yourself: 'P'(] , (,. ,.))'N'(] , (,. ,.))'D'(] , (,. ,.))'Q'(] , (,. ,.))' ' Q D DQ N NQ ND NDQ P PQ PD PDQ PN PNQ PND PNDQ From there, it can also be helpful to look at further intermediate results 'Q'(] , (,. ,.))' ' Q 'D'(] , (,. ,.))'Q'(] , (,. ,.))' ' Q D DQ ... I hope this helps, -- Raul On Sun, Dec 16, 2018 at 8:35 PM Linda Alvord <lindaalvor...@outlook.com> wrote: > > Louis, That's impressive. I did a little > Cosmetics. > > acl=: 13 :'|:(] , (,. ,.))/y' > > acl 'HQDNP ' > PNNDDDDQQQQQQQQHHHHHHHHHHHHHHHH > P PNN PNNDDDD PNNDDDDQQQQQQQQ > P P PNN P PNN PNNDDDD > P P P PNN > P > acl > [: |: (] , (,. ,.))/ > > > > Now my challenge is understand how it wors well enough to explain it to > others. > > Thanks, Linda acl > > -----Original Message----- > From: Programming <programming-boun...@forums.jsoftware.com> On Behalf Of > Louis de Forcrand > Sent: Sunday, December 16, 2018 5:09 PM > To: programm...@jsoftware.com > Subject: Re: [Jprogramming] (no subject) > > Hi, > > This is very similar to what you’re doing (you have to transpose the result > to get exactly what you want): > > AC=: ({.~ -@>:@#) {~ #\ *"1 [: #:@i. 2 ^ # > |:AC 'PNDQ' > PPPPPPPP > NNNN NNNN > DD DD DD DD > Q Q Q Q Q Q Q Q > > > This one is quite cute if you don’t care about the aligning of the columns, > but it only works for vectors, and a space / zero must be appended at the end > of the vector: > > (] , (,. ,.))/'PNDQ ' > > Q > D > DQ > N > NQ > ND > NDQ > P > PQ > PD > PDQ > PN > PNQ > PND > PNDQ > > > Cheers, > Louis > > > On 16 Dec 2018, at 02:50, lindaalvord <lindaalv...@verizon.net> wrote: > > > > > > In 1984 I wrote a little paperback called “Probility in APL”. I have > > been thinking about combination. So I translated three verbs to provide all > > the ways ‘PNDQ’ or a penny, nickel, dime and quarter could be combined. > > > > Possible outcomes: > > po=: 13 :'|:y#:i.*/y' > > po 2 2 2 2 > > 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 > > 0 0 0 0 1 1 1 1 0 0 0 0 1 1 1 1 > > 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 > > 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 > > Correction matrix: (array) > > > > cm=: 13 :'(*/y)(#"0) 0,}:+/y' > > cm 2 2 2 2 > > 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 > > 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 > > 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 > > 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 > > All combinations as chafacters: > > > > ac=: 13 :'((po + cm) ($y)#2){,'' '',.y' > > ac 'PNDQ' > > PPPPPPPP > > NNNN NNNN > > DD DD DD DD > > Q Q Q Q Q Q Q Q > > Each column is possible combination of the coins. > > > > I’m interested to know a better way to get this conclusion. > > > > Linda > > > > > > > > Sent from my Verizon, Samsung Galaxy smartphone > > ---------------------------------------------------------------------- > > For information about J forums see > > https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.j > > software.com%2Fforums.htm&data=02%7C01%7C%7C5e5b77214fed4a7ce9d308 > > d663a31a0e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C63680594949679 > > 4717&sdata=tq4mny21riot%2BKHKegpf0jCe7WIKxNuhmNLeGbTO4dI%3D&re > > served=0 > ---------------------------------------------------------------------- > For information about J forums see > https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.jsoftware.com%2Fforums.htm&data=02%7C01%7C%7C0c0ffac938a84819ad1008d66440843e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636806625588159753&sdata=rlP4cPCFucv5Jvn6yCvm5gCAtwLqXuuiZ8yP63mZUZc%3D&reserved=0 > ---------------------------------------------------------------------- > For information about J forums see > https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.jsoftware.com%2Fforums.htm&data=02%7C01%7C%7C0c0ffac938a84819ad1008d66440843e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636806625588159753&sdata=rlP4cPCFucv5Jvn6yCvm5gCAtwLqXuuiZ8yP63mZUZc%3D&reserved=0 ---------------------------------------------------------------------- For information about J forums see https://nam01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.jsoftware.com%2Fforums.htm&data=02%7C01%7C%7C0c0ffac938a84819ad1008d66440843e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636806625588159753&sdata=rlP4cPCFucv5Jvn6yCvm5gCAtwLqXuuiZ8yP63mZUZc%3D&reserved=0 ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm