[:g^:({.`{:),

R.E. Boss

(Add your info to http://www.jsoftware.com/jwiki/Community/Demographics )


-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Ric Sherlock
Sent: vrijdag 20 september 2013 2:41
To: Programming JForum
Subject: Re: [Jprogramming] 13 : '(g^:x)y'

or:
f3=: g@]^:[



On Fri, Sep 20, 2013 at 10:56 AM, Don Guinn <[email protected]> wrote:

> Don't know why it didn't, but it took me forever to write it tacit myself.
>
>    f2=.([:g])^:[
>
> f2
>
> +--------+--+-+
>
> |+--+-+-+|^:|[|
>
> ||[:|g|]|| | |
>
> |+--+-+-+| | |
>
> +--------+--+-+
>
> 45 f 27
>
> 4616
>
>
> On Thu, Sep 19, 2013 at 3:16 PM, Bo Jacoby <[email protected]> wrote:
>
> >    g=.-:&(+ (2&|*>:&+:)) NB. (g y)= 2%~1+3*y if y is odd, (g y)=2%~y 
> > if y is even.
> >    f=.13 : '(g^:x)y'
> >    f
> >
> > 4 : '(g^:x)y'
> >
> >
> > I wonder why  f  is not translated into tacit code.
> >
> > It works nevertheless:
> >    45 f 27
> > 4616
> > --------------------------------------------------------------------
> > -- 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

Reply via email to