Linda,
Thank you for your f, g, and h examples.
Together with Henry's long explanations, they helped me better able to
understand the tree form. I think **now** I can see that the order of
parsing is from left to right before execution which is from bottom to top.
I used the fork example tree below to see this as well.
k =: % %: - + *:
5!:4 <'k'
┌─ %
├─ %:
──┤ ┌─ -
└────┼─ +
└─ *:
g=: 13 :'%@%:@-@+@*:y'
5!:4 <'g'
┌─ %
┌─ @ ─┴─ %:
┌─ @ ─┴─ -
┌─ @ ─┴─ +
── @ ─┴─ *:
Now compare the trees of g and k above. (For purposes of comparison, the
defined k was constructed with the same order of verbs as the defined g.)
Both the definitions of g and k are unadorned with parentheses and both are
executed from bottom to top in their respective trees. But whereas g's tree
is upward sloping, k's is downward sloping and the right to left parsing
order in the trees describe the opposition of the two.
These relative asymmetries **show** me a little better why you have for a
long time wanted to concentrate on developing verbs in only one of the two
ways (using forks and not conjunctions, in your case) to limit complexity.
On Sat, Jan 23, 2016 at 11:08 PM, Linda A Alvord <[email protected]>
wrote:
> Guess how this tree will look before you look.
>
> h=: 13 :'((((%@%:)@-)@+)@*:)y'
> 5!:4 <'h'
>
> Linda
>
> -----Original Message-----
> From: Programming [mailto:[email protected]] On
> Behalf Of Linda A Alvord
> Sent: Saturday, January 23, 2016 2:01 AM
> To: [email protected]
> Subject: Re: [Jprogramming] @ and @: (atop and at)
>
> Henry, Your explanation of how the conjunctions are parsed helped make the
> tree diagrams make more sense. I gave up my idea.
>
>
>
> f=: 13 :'(%@(%:@(-@(+@*:))))y'
>
> 5!:4 <'f'
>
> ┌─ %
>
> ── @ ─┤ ┌─ %:
>
> └─ @ ─┤ ┌─ -
>
> └─ @ ─┤ ┌─ +
>
> └─ @ ─┴─ *:
>
> g=: 13 :'%@%:@-@+@*:y'
>
> 5!:4 <'g'
>
> ┌─ %
>
> ┌─ @ ─┴─ %:
>
> ┌─ @ ─┴─ -
>
> ┌─ @ ─┴─ +
>
> ── @ ─┴─ *:
>
>
> --
(B=)
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm