[Jprogramming] Bond, Compose, Atop, etc.

David Vaughan purpleblues13 at googlemail.com
Thu Oct 27 22:13:13 HKT 2011


I've been trying to properly understand how @,@:,&, and &: work, but I'm struggling a bit it would seem.
My understanding of @ is that with more than one use in its dyadic form, you get this behaviour:

   x f at g@h y === f g x h y

And I understand the difference between the colon and non-colon versions of both.

What is confusing me most is the interplay between them in longer trains of verbs. For example, why don't these expressions work?

   {. at 2&x:@(+%)/ 1 2
|domain error
|       {. at 2&x:@(+%)/1 2
   {.&2&x:@(+%)/ 1 2
|domain error
|       {.&2&x:@(+%)/1 2


More information about the Programming mailing list