I don't know how simplified your example is compared to your real problem, but any loop in J makes me suspicious.
Your example, as stated, could be done without looping like this: example=: 3 : '>y$<i.2 3' $example 3 3 2 3 But perhaps your real problem can't be simplified this far. On Mon, Nov 9, 2009 at 8:17 AM, Matthew Brand <[email protected]>wrote: > By the way, the problem for me arises because of the way I am appending > data > in a loop. Is there a better way to do this rather than , ,: followed by > }. > at the end? > > $ example '' > 1 2 3 > example =: 3 : 0 > output =. '' > for_i. i. y do. > output =. output , ,: i. 2 3 > end. > }. output > ) > ... > -- Devon McCormick, CFA ^me^ at acm. org is my preferred e-mail ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
