Damn, I just tried prefixing a whole bunch of monadic verbs with an
integer, and it did indeed apply them N many times.  What's the point of
the power function ^: then?  More importantly, where exactly is this
documented?  J never stops surprising me, though sometimes I wonder if
that's a good thing!



On 30 April 2014 17:15, km <[email protected]> wrote:

> Your func2 is a "hook", see the diagram at
>
> http://www.jsoftware.com/docs/help801/dictionary/dictf.htm
>
> You may also need to understand the dyadic case of m&v , see
>
> http://www.jsoftware.com/docs/help801/dictionary/d630n.htm
>
> --Kip Murray
>
> Sent from my iPad
>
> > On Apr 30, 2014, at 10:42 AM, Jon Hough <[email protected]> wrote:
> >
> > I can't understand why
> > func1 =. 3&+ @: (2&-)
> > func2 =. (3&+) (2&-)
> >
> > give different results as mondaic verbs.
> > func1 5 gives 0, which is what I would expect.
> > func2 5 gives 12, which I can't understand.
> > I would like to know what the difference is between func1 and func2. It
> is my understanding that for monadic verbs @: is optional, so doesn't add
> anything to the meaning of the whole verb.
> > Regards.
> > ----------------------------------------------------------------------
> > 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

Reply via email to