Hi Viktor, I seem to get a syntax error from your definitions. I am just starting to play around with the Evoke Gerund (`:) so I don't know all of its finer points, but I am not sure how you get an adverb from this. My understanding that Evoke Gerund creates verbs (but this would not be the first time I am wide of the mark).
Cheers, bob On 2010-12-15, at 4:23 AM, Viktor Cerovski wrote: > > > bob therriault-2 wrote: >> >> Somewhat surprisingly (to me) >> >> av2=: 1 : 'm*-~' >> >> also works the same way. >> > Tacit version: > > av2t =: ("_)(`*`(-~))(`:6) > > which can be simplified to: > > av2t1 =: ("_)(`*`-)(`:6)~ > > > PS: Typed on a handheld device. > > > >> Cheers, bob >> >> On 2010-12-14, at 4:48 PM, Tikkanz wrote: >> >>> Or just >>> adv2 =: 1 : (':';'m*y-x') >>> >>> See http://www.jsoftware.com/help/dictionary/d310n.htm >>> and http://www.jsoftware.com/help/dictionary/dicth.htm >>> >>> On Wed, Dec 15, 2010 at 1:39 PM, bill lam <bbill....@gmail.com> wrote: >>>> In pre-historic J, multi-line explicit definition was defined as array >>>> of >>>> boxed strings. >>>> adv2=: 1 : ('';':';'m*y-x') >>>> >>>> Срд, 15 Дек 2010, Graham Parkhouse писал(а): >>>>> How can I write an adverb that returns a noun from 3 noun arguments x, >>>>> m and >>>>> y as a *one liner*? >>>>> >>>>> Just 2 arguments is fine: >>>>> adv1=: 1 : 'm*y' >>>>> 3 adv1 10 >>>>> 30 >>>>> >>>>> 3 arguments like this doesn't work: >>>>> adv2=: 1 : 'm*y-x' >>>>> 5 (3) adv2 10 >>>>> |domain error >>>>> | 5 (3)adv2 10 >>>>> >>>>> Giving it a body works: >>>>> adv3=: 1 : 0 >>>>> : >>>>> m*y-x >>>>> ) >>>>> 5 (3) adv3 10 >>>>> 15 >>>>> >>>>> Is there a way to do it as one liner? >>>>> >>>>> Regards >>>>> >>>>> Graham Parkhouse >>>>> >>>>> >>>>> ---------------------------------------------------------------------- >>>>> For information about J forums see http://www.jsoftware.com/forums.htm >>>> >>>> -- >>>> regards, >>>> ==================================================== >>>> GPG key 1024D/4434BAB3 2008-08-24 >>>> gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3 >>>> ---------------------------------------------------------------------- >>>> 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 >> > > -- > View this message in context: > http://old.nabble.com/Explicit-adverbs-tp30459928s24193p30463335.html > Sent from the J Programming mailing list archive at Nabble.com. > > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm