But consider this:
oleg=: /:@({~ i.~)
x=: 1++/\ 1000$2^_44
x=: 1++/\ 1000$2^_44
(tgu -: tgu3) i{x [ i=: ?~#x
1
(oleg -: tgu3) i{x
0
Tolerant grade is a pretty tricky thing. It's
not for no reason that the primitive /: is
not tolerant.
----- Original Message -----
From: Oleg Kobchenko <[EMAIL PROTECTED]>
Date: Friday, June 1, 2007 6:48 am
Subject: Re: [Jgeneral] Re: Challenge to expert J'ers
> (/:@({~ i.~) -: tgu3) x
> 1
>
> ts 'tgu3 x'
> 1.29363 4.2994e7
>
> ts '/:@({~ i.~) x'
> 1.22371 1.73028e7
>
>
> --- Roger Hui <[EMAIL PROTECTED]> wrote:
>
> > tgu3=: 3 : 0
> > i=. /:y
> > p=. 1 (0})^:(*#y) (~: _1&|.) i{y
> > i/:i++/\p*#y
> > )
> >
> > x=: ,(0,-9!:18'')+/1+i.5e5
> > (tgu -: tgu3) x
> > 1
> >
> > ts=: 6!:2 , 7!:[EMAIL PROTECTED]
> > ts 'tgu x'
> > 2.62876 1.15827e8
> > ts 'tgu3 x'
> > 1.54044 3.9324e7
> >
> >
> >
> > ----- Original Message -----
> > From: [EMAIL PROTECTED]
> > Date: Thursday, May 31, 2007 4:10 pm
> > Subject: Re: [Jgeneral] Re: Challenge to expert J'ers
> >
> > > I also forgot the empty case (shame on me) so here they are again:
> > > tgu=: 3 : 0
> > > if. (0 e. $ y) do. y return. end.
> > > ix=./:y
> > > sy=.ix{y
> > > p=.sy~:_1|.sy
> > > one=.1
> > > p=.one 0}p
> > > sy=.p < ;.1 ix{i.#y
> > > ;(/:&.>sy){&.>sy
> > > )
> > >
> > > tgd=: 3 : 0
> > > if. (0 e. $ y) do. y return. end.
> > > ix=.\:y
> > > sy=.ix{y
> > > p=:sy~:_1|.sy
> > > one=.1
> > > p=.one 0}p
> > > sy=.p < ;.1 ix{i.#y
> > > ;(\:&.>sy){&.>sy
> > > )
> > -----------------------------------------------------------------
> -----
> > For information about J forums see
> http://www.jsoftware.com/forums.htm>
>
>
>
>
> ____________________________________________________________________________________Park
> yourself in front of a world of choices in alternative vehicles. Visit the
> Yahoo! Auto Green Center.
> http://autos.yahoo.com/green_center/
> -------------------------------------------------------------------
> ---
> For information about J forums see http://www.jsoftware.com/forums.htm
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm