meaning of J phrase: 10&+~20 -
i trying 20 + 10 in such way as:
(10&+~) 20 then realize adverb & has "short right-hand". should be
(10&(+~)) 20 which gives me correct answer: 30. out of curiosity
(10&+~) 20 gives 220. why?
more strangely,
(10&+~) 0.1 gives "domain error'
(10&+~) 20 10 (&+~) 20. seems fork or hook isn't because ~ , & special snowflakes. ~ has dealt first, expression 10 (&+)~ 20. now, &+ can not stand on own, ~ has reflexive here. expression is
20 (10 (&+)) 20 which leads special dyadic case of bond-& becomes power (^:): x m&v y ↔ m&v^:x y. so, finally, expression becomes:
(10&+)^:20 ] 20 220 obviously, can't use power non-integers, (10&+~)0.1 domain error.
Comments
Post a Comment