Mijj, Two points I wish to make:
1. There is no "natural" order of writing or reading arithmetic - it is all learned behavior, based on your culture. 2. Given x F y, it should be clear that both x and y must be evaluated before it can be passed by value to the function F. But if y is an expression itself? Say, r G s, then the original expression would have been, with substitution: x F r G s Surely you can see that the value of s must be evaluated before being passed by value to the function G? Even more interesting is to consider the possibility of nomadic vs dyadic functions. This requires parsing the function name or expression to determine the valence before it can be determined whether to pass y or both x and y. The problem of function modifiers (adverbs) is left to others to reflect on. So, we may think in order of L->R, but the computer must evaluate in R->L in order to pass values or parse function valences. Sent from my iPhone On Aug 14, 2011, at 5:07 AM, mijj <[email protected]> wrote: > but J .. beautiful as it is, isn't just for looking at .. it's for > constructing. Design may be top down, but our thoughts in terms of > construction form an expression beginning with the detail and develop > towards the final outocome - and our characters appear on the page from > L->R. > > So, taking the example from > http://www.jsoftware.com/papers/EvalOrder.htm > > to determine the divisiblity of a number(n) by 9 ... > (d : n's digits) > > L->R flows naturally from the keyboard > d/+|9=0 > .. unlike L<-R ( 0=9|+/d ) , there's no having to keep in mind an > imagined expression which is being operated on on the right while > construction is taking place. > > for L<-R there's conflict between natural direction of construction and > the direction of the expression on the line. > > > > > On 2011-08-14 06:56, Raul Miller wrote: >> On Sat, Aug 13, 2011 at 11:05 PM, mijj<[email protected]> wrote: >>> .. plus .. while on the subject of direction .. why was APL thus J >>> direction of evaluation set to be right to left? .. wouldn't it'd be >>> more natural as left to right? (ie. the same direction as writing, or >>> the direction which represents the progression of time) >> >> If you look at J top down, it is left to right. >> >> If you look at J bottom up, it is right to left. >> >> V=: 1 + 1 >> >> If J reversed its evaluation order, how would that work? >> > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
