Why, Linda, do you ever want to go from the tacit expression to an explicit expression?
a =: ((+/ % #) * 1 + #) - +/ a 90 90 90 90 NB. ((+/ % #) * (1 + #)) === (((+/ % #) * 1) + ((+/ % #) * #)) === ((+/ % #) + ((+/)) a =: +/ % # a 90 90 90 90 >________________________________ >Fra: Björn Helgason <[email protected]> >Til: Programming forum <[email protected]> >Sendt: 13:16 fredag den 7. oktober 2011 >Emne: Re: [Jprogramming] Tacit vs. Explicit > >Is this what you are looking for? > > load'c:\j701\addons\general\misc\trace.ijs' > trace'(((+/ % #) * 1 + #) - +/)90 90 90' > > >2011/10/7 Linda Alvord <[email protected]> > >> Is there a way to go from a tacit expression to find the correct explicit >> expression? >> >> a =: 13 :'((+/ % #) * 1 + #) - +/' >> a 90 90 90 >> |syntax error: a >> | a 90 90 90 >> >> b=:((+/ % #) * 1 + #) - +/ >> b 90 90 90 >> 90 >> >> c =: 13 :'((+/ % #) * 1 + #) - +/y' >> c 90 90 90 >> _540 >> >> d =: 13 :'((+/ % #) * 1 + #y) - +/y' >> d 90 90 90 >> _269 >> >> e=: 13 :'((+/ % #y) * 1 + #y) - +/y' >> e 90 90 90 >> _268.667 >> >> >> a >> 3 : '((+/ % #) * 1 + #) - +/' >> b >> ((+/ % #) * 1 + #) - +/ >> c >> [: ((+/ % #) * 1 + #) [: - +/ >> d >> ([: (+/ % #) [: * 1 + #) - +/ >> e >> (([: +/ [: % #) * 1 + #) - +/ >> >> >> >> 5!:4 <'a' >> >> -- 3 >> -- : -+- ,:'((+/ % #) * 1 + #) - +/' >> >> >> 5!:4 <'b' >> >> -- / --- + >> ----+- % >> │ L- # >> ------+- * >> │ │ -- 1 >> │ L---+- + >> --+ L- # >> +- - >> L- / --- + >> >> >> 5!:4 <'c' >> >> -- [: >> │ -- / --- + >> │ ------+- % >> │ │ L- # >> +----+- * >> --+ │ -- 1 >> │ L-----+- + >> │ L- # >> │ -- [: >> L----+- - >> L- / --- + >> >> >> 5!:4 <'d' >> >> -- [: >> │ -- / --- + >> +----+- % >> │ L- # >> ------+ >> │ │ -- [: >> │ │ +- * >> │ L----+ -- 1 >> --+ L-----+- + >> │ L- # >> +- - >> L- / --- + >> >> >> >> >> >> 5!:4 <'e' >> >> -- [: >> +- / --- + >> ----+ >> │ │ -- [: >> │ L-----+- % >> ------+ L- # >> │ +- * >> │ │ -- 1 >> --+ L---+- + >> │ L- # >> +- - >> L- / --- + >> >> Do you get the answer you want with b, c, d or e? I would have guessed it >> should be b , that doesn't seem to be very helpful. >> >> -----Original Message----- >> From: [email protected] >> [mailto:[email protected]] On Behalf Of Henry Rich >> Sent: Wednesday, October 05, 2011 5:25 AM >> To: Programming forum >> Subject: Re: [Jprogramming] Tacit vs. Explicit >> >> bestfit=:(],0{&<.&<.0.5+(1+0.01*_15+(?@(30"_)))*(((+/ % #)*1+#)-(+/))) >> bestfit 90 90 90 >> 90 90 90 101 >> bestfit 90 90 90 >> 90 90 90 102 >> bestfit 90 90 90 >> 90 90 90 103 >> bestfit 90 90 90 >> 90 90 90 78 >> >> Henry Rich >> >> On 10/5/2011 5:19 AM, Gian Medri wrote: >> > Hi! >> > I have a function: >> > bestfit=:(],0{&<.&<.0.5+(1+0.01*(?30)-15)*(((+/ % #)*1+#)-(+/))) >> > that calculates the n+1 element. >> > bestfit 90 90 90 >> > 90 90 90 81 >> > The tacit form doesn't work properly, because the "?" is not active every >> > time I call bestfit 90 90 90. >> > When I use >> > (],0{&<.&<.0.5+(1+0.01*(?50)-25)*(((+/ % #)*1+#)-(+/))) 90 90 90 >> > then the function works properly. >> > >> > My question is if it is possible to have a tacit verb with the "?" >> active. >> > >> > Thanks >> > >> > Gian Medri >> > ---------------------------------------------------------------------- >> > 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 >> > > > >-- >Björn Helgason, Verkfræðingur >Fornustekkum II >781 Hornafirði, >t-póst: [email protected] >gsm: +3546985532 >twitter: @flugfiskur >http://groups.google.com/group/J-Programming > > >Tæknikunnátta höndlar hið flókna, sköpunargáfa er meistari einfaldleikans > >góður kennari getur stigið á tær án þess að glansinn fari af skónum > /|_ .-----------------------------------. > ,' .\ / | Með léttri lund verður | > ,--' _,' | Dagurinn í dag | > / / | Enn betri en gærdagurinn | > ( -. | `-----------------------------------' > | ) | (\_ _/) > (`-. '--.) (='.'=) ♖♘♗♕♔♙ > `. )----' (")_(") ☃☠ >---------------------------------------------------------------------- >For information about J forums see http://www.jsoftware.com/forums.htm > > ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
