[Jprogramming] fully parenthesized representation of a tacit verb
Raul Miller
rauldmiller at gmail.com
Thu Jul 26 15:34:31 UTC 2012
On Wed, Jul 25, 2012 at 11:47 PM, Ian Clark <earthspotty at gmail.com> wrote:
>> m=: v^:x y NB. dyadic(&) --> (^:)
>> n=: u"v m NB. Brian's suggestion for (@)
>
> Bearing in mind what Raul said earlier, I don't think this is general
> enough. Maybe (@) is unavoidable in dealing with how u and v operate
> together.
It's not unavoidable.
Here's an implementation of atop that does not use @
atopA=: 2 :'([: u v)"v'
Here's another approach:
atopB=: 2 :'[: u@> <@v'
That said, note that if side effects are involved, atopB reschedules
those side effects, and this can be an issue (if the schedule was
important).
FYI,
--
Raul
More information about the Programming
mailing list