Early J supported a variety of trains that are not currently supported (and which, sadly, can't be re-enabled using a foreign).
That said, you can still achieve their results using explicit definitions. However, in explicit definitions, some names are reserved: m n u v x y So I would first use a different name than 'v': V=:+*: WIth that out of the way, I can go: incrby=:1 :'(u (&>) i.) y' V incrby 6 6 7 10 15 22 31 Thanks, -- Raul On Fri, May 31, 2019 at 2:23 PM Ulrich Vollert <[email protected]> wrote: > > Norman Thompson defines a verb > > v =: +*: > > which computes n(n+1). > > Now > > (v i.) 6 > > gives y + i*i (i=0,1,..,y) > > 6 7 10 15 22 31 > > and then he says: „This can be generalized by defining an adverb: > > incrby =: (&>) i. > v incrby 6 > 6 7 10 15 22 31 > " > > which I really don’t understand and which is a syntax error in > j807/j64/darwin. > > > > Am 31.05.2019 um 20:05 schrieb 'Pascal Jasmin' via Programming > > <[email protected]>: > > > > can you tell us what the function is expected to do? > > &> is an unboxing adverb > > (a v) is a syntax error. But perhaps an early version of J, it wasn't. > > > > > > On Friday, May 31, 2019, 2:00:00 p.m. EDT, Ulrich Vollert > > <[email protected]> wrote: > > > > Hello, > > > > I am reading „J: The natural language for analytic computing“ and on page > > 47 the author defines an adverb > > > > incrby =: (&>) i. > > > > which leads to a syntax error if I try to define it. > > > > Any hint what is going on? > > > > Regards, > > Ulrich > > > > > > ---------------------------------------------------------------------- > > 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 ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
