I can imagine explicit and. and or. keywords... But, the usual cases would be:
cheapnoun and. expensivenoun cheapnoun or. expensivenoun It might make sense to also define true/false verbs, adverbs, and conjunctions but those might also be coding errors. That said, this kind of code would tend to have relatively expensive constant time overhead, so there's a rational argument that it should also be verbose. Thanks, -- Raul On Monday, November 6, 2017, Henry Rich <henryhr...@gmail.com> wrote: > Using ^: is a clever idea. But it makes heavy work of a simple and useful > case. If I want the equivalent of > > if. cheapverb y and. expensiveverb y do. > end. > > I have these options: > > if. cheapverb y do. if. expensiveverb y do. > end. end. > > if. cheapverb y do. expensiveverb y else. 0 end. do. > end. > > if. (expensiveverb@[^:] cheapverb) y do. > end. > > > I think it makes a pretty good case for and. . > > Henry Rich > > On 11/6/2017 1:55 PM, Raul Miller wrote: > >> Probability is extremely low, since the parser does not hand control >> to the verb until after both nouns have been computed. You can even >> write code which abuses this (though that tends to be hard to >> understand so few people like that sort of thing - but trying to >> forbid foolish code at the language level tend to cripple things.) >> >> ^: on the other hand, puts control of this in the hands of the >> programmer (its argument is two verbs and the right verb can control >> whether he left verb does anything). >> >> Thanks, >> >> > > --- > This email has been checked for viruses by AVG. > http://www.avg.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