I planned (and used) conjunctions for both parts to take advantage of the binding preference of conjunctions. I'd need fewer parens.
4 (2 : 'm+n') 3 , 1 7 1 4 + 3 , 1 7 5 the conjunction executes before , It refers to the R or RB in the generated string/code. ----- Original Message ----- From: Brian Schott <[email protected]> To: Programming forum <[email protected]> Sent: Saturday, December 10, 2016 11:47 PM Subject: Re: [Jprogramming] AoC 2016 day 9 - Was Re: [Jbeta] possible memory leak j805 Yes, my bad. I was *blind* to the left-most 1 in the expression below. (1 +/@:".@:}.@:p1 n) But what about the rest of my questions: a) When you first did part 1 did you use a conjunction, or was the conjunction only needed in part 2, and so you revised part 1 to be similar? b) And you state, "a conjunction binds its (right) arguments ahead of a verb." Can you be specific about what verb you mean here. Is it the p1 that is referred to inside of RB or some other verb? By the way, I have considered putting my solution on the wiki as one NOT to do because it is so inefficient it takes over 2 hours. You see, I constructed all of the expanded strings and only counted their length after all was computed. I think the time may have been exaggerated by all of the disk swapping that must have been required. So I really was astonished by the speed of your solution. Thanks, again. On Sat, Dec 10, 2016 at 11:29 PM, 'Pascal Jasmin' via Programming < [email protected]> wrote: > part 1 emits R, part 2 emits RB. RB parses the string in n argument with > 1&p1 (which will emit RBs recursively) > > the x argument of p1 determines whether its part 1(R) or part 2(RB) format. > > > > > > ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
